]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
check that multiple KEY-TAG trust-anchor-telemetry options don't leak memory
authorMark Andrews <marka@isc.org>
Mon, 10 Dec 2018 02:33:54 +0000 (13:33 +1100)
committerEvan Hunt <each@isc.org>
Mon, 4 Feb 2019 23:08:48 +0000 (15:08 -0800)
(cherry picked from commit 4c307aebdf08b938f845a5c55004463222abba09)

bin/tests/system/dnssec/tests.sh

index 7bea2428fbcc95f809322da50fed7293c179b4d4..343de9421ca575ec40cd76f28f0cce981650fc8d 100644 (file)
@@ -3519,12 +3519,23 @@ status=`expr $status + $ret`
 
 echo_i "check that KEY-TAG trust-anchor-telemetry queries are logged ($n)"
 ret=0
-$DIG $DIGOPTS . dnskey +ednsopt=KEY-TAG:ffff @10.53.0.1 > dig.out.ns4.test$n || ret=1
+$DIG $DIGOPTS . dnskey +ednsopt=KEY-TAG:ffff @10.53.0.1 > dig.out.ns1.test$n || ret=1
 grep "trust-anchor-telemetry './IN' from .* 65535" ns1/named.run > /dev/null || ret=1
 n=`expr $n + 1`
 if [ $ret != 0 ]; then echo_i "failed"; fi
 status=`expr $status + $ret`
 
+echo_i "check that multiple KEY-TAG trust-anchor-telemetry options don't leak memory ($n)"
+ret=0
+$DIG $DIGOPTS . dnskey +ednsopt=KEY-TAG:fffe +ednsopt=KEY-TAG:fffd @10.53.0.1 > dig.out.ns1.test$n || ret=1
+grep "trust-anchor-telemetry './IN' from .* 65534" ns1/named.run > /dev/null || ret=1
+grep "trust-anchor-telemetry './IN' from .* 65533" ns1/named.run > /dev/null && ret=1
+$PERL $SYSTEMTESTTOP/stop.pl . ns1 || ret=1
+$PERL $SYSTEMTESTTOP/start.pl --noclean --restart --port ${PORT} . ns1 || ret=1
+n=$(($n+1))
+test "$ret" -eq 0 || echo_i "failed"
+status=$((status+ret))
+
 echo_i "check that the view is logged in messages from the validator when using views ($n)"
 ret=0
 grep "view rec: *validat" ns4/named.run > /dev/null || ret=1