summaryrefslogtreecommitdiff
path: root/smoketest/scripts
diff options
context:
space:
mode:
authorChristian Poessinger <christian@poessinger.com>2022-07-05 12:25:44 +0200
committerGitHub <noreply@github.com>2022-07-05 12:25:44 +0200
commit373aacd2375f35400a351345b2fa849efdae0543 (patch)
tree9f21d48dff52fe9c22f6780d6feae33f11617a8a /smoketest/scripts
parent1520deeddfb6928e0b7053a6f526909407868dfd (diff)
parent2bdf4798570222b57af2de2f0b443529abdc3feb (diff)
downloadvyos-1x-373aacd2375f35400a351345b2fa849efdae0543.tar.gz
vyos-1x-373aacd2375f35400a351345b2fa849efdae0543.zip
Merge pull request #1389 from sever-sever/T4509
dns: T4509: Add dns64-prefix option
Diffstat (limited to 'smoketest/scripts')
-rwxr-xr-xsmoketest/scripts/cli/test_service_dns_forwarding.py11
1 files changed, 11 insertions, 0 deletions
diff --git a/smoketest/scripts/cli/test_service_dns_forwarding.py b/smoketest/scripts/cli/test_service_dns_forwarding.py
index 5929f8cba..dcc0dc1e2 100755
--- a/smoketest/scripts/cli/test_service_dns_forwarding.py
+++ b/smoketest/scripts/cli/test_service_dns_forwarding.py
@@ -51,6 +51,7 @@ class TestServicePowerDNS(VyOSUnitTestSHIM.TestCase):
# Check basic DNS forwarding settings
cache_size = '20'
negative_ttl = '120'
+ dns_prefix = '64:ff9b::/96'
self.cli_set(base_path + ['cache-size', cache_size])
self.cli_set(base_path + ['negative-ttl', negative_ttl])
@@ -67,6 +68,12 @@ class TestServicePowerDNS(VyOSUnitTestSHIM.TestCase):
for address in listen_adress:
self.cli_set(base_path + ['listen-address', address])
+ # Check dns64-prefix - must be prefix /96
+ self.cli_set(base_path + ['dns64-prefix', '2001:db8:aabb::/64'])
+ with self.assertRaises(ConfigSessionError):
+ self.cli_commit()
+ self.cli_set(base_path + ['dns64-prefix', dns_prefix])
+
# configure DNSSEC
self.cli_set(base_path + ['dnssec', 'validate'])
@@ -100,6 +107,10 @@ class TestServicePowerDNS(VyOSUnitTestSHIM.TestCase):
tmp = get_config_value('serve-rfc1918')
self.assertEqual(tmp, 'yes')
+ # dns64-prefix
+ tmp = get_config_value('dns64-prefix')
+ self.assertEqual(tmp, dns_prefix)
+
# Check for running process
self.assertTrue(process_named_running(PROCESS_NAME))