[master] truncate logged rdata if too long

3490.	[bug]		When logging RDATA during update, truncate if it's
                        too long. [RT #32365]

cherry picked from:
        commit 16ddb566e5a5b57bf925adef2b5543dddc1de49b
        commit cd97e0c23b09f38aac49aabab66ee13c68b7a3f3
        commit d087fa982649c081d58c5bb16e63da3428e2b89d
        commit d0795bdffef57612dd7654ffd09c9f4216eee2c8
This commit is contained in:
Evan Hunt
2013-02-20 13:54:52 -08:00
parent 9d8985bea9
commit 2425d8bb7c
6 changed files with 37 additions and 11 deletions

View File

@@ -552,5 +552,17 @@ if [ $ret -ne 0 ]; then
status=1
fi
n=`expr $n + 1`
ret=0
echo "I:add a record which is truncated when logged. ($n)"
$NSUPDATE verylarge || ret=1
$DIG +tcp @10.53.0.1 -p 5300 txt txt.update.nil > dig.out.ns1.test$n
grep "ANSWER: 1," dig.out.ns1.test$n > /dev/null || ret=1
grep "adding an RR at 'txt.update.nil' TXT .* \[TRUNCATED\]" ns1/named.run > /dev/null || ret=1
if [ $ret -ne 0 ]; then
echo "I:failed"
status=1
fi
echo "I:exit status: $status"
exit $status

File diff suppressed because one or more lines are too long