2
0
mirror of https://gitlab.isc.org/isc-projects/bind9 synced 2025-08-30 05:57:52 +00:00

Check that 'provide-zoneversion no;' works

This commit is contained in:
Mark Andrews 2024-08-29 10:09:34 +10:00
parent 9428e32b13
commit eb77a89dfd
2 changed files with 10 additions and 0 deletions

View File

@ -36,4 +36,5 @@ zone "example" {
zone "example.tld" {
type primary;
file "example.tld.db";
provide-zoneversion no;
};

View File

@ -810,6 +810,15 @@ if [ -x "$DIG" ]; then
if [ $ret -ne 0 ]; then echo_i "failed"; fi
status=$((status + ret))
n=$((n + 1))
echo_i "checking dig +zoneversion to a authoritative server with zoneversion disabled ($n)"
ret=0
dig_with_opts @10.53.0.2 +zoneversion a.example.tld >dig.out.test$n 2>&1 || ret=1
grep "status: NOERROR" dig.out.test$n >/dev/null || ret=1
grep "; ZONEVERSION:" dig.out.test$n >/dev/null && ret=1
if [ $ret -ne 0 ]; then echo_i "failed"; fi
status=$((status + ret))
if [ $HAS_PYYAML -ne 0 ]; then
n=$((n + 1))
echo_i "checking dig +yaml +zoneversion to a authoritative server ($n)"