3396. [bug] OPT records were incorrectly removed from signed,

truncated responses. [RT #31439]
This commit is contained in:
Mark Andrews
2012-10-18 13:25:06 +11:00
parent 4b93750c5d
commit 0fbd29837a
5 changed files with 56 additions and 25 deletions

View File

@@ -222,6 +222,17 @@ if [ $ret -eq 1 ] ; then
echo "I: failed"; status=1
fi
echo "I:checking both OPT and TSIG records are returned when TC=1"
ret=0
$DIG +ignore +bufsize=512 large.example.nil \
-y "hmac-sha1:sha1:$sha1" @10.53.0.1 txt -p 5300 > dig.out.large 2>&1 || ret=1
grep "flags:.* tc[ ;]" dig.out.large > /dev/null || ret=1
grep "status: NOERROR" dig.out.large > /dev/null || ret=1
grep "EDNS:" dig.out.large > /dev/null || ret=1
grep -i "sha1.*TSIG.*NOERROR" dig.out.sha1 > /dev/null || ret=1
if [ $ret -eq 1 ] ; then
echo "I: failed"; status=1
fi
exit $status