loop waiting for stub zone to transfer

This commit is contained in:
Mark Andrews
2011-11-02 08:17:01 +00:00
parent bd46bf198d
commit e223d4bb26

View File

@@ -15,7 +15,7 @@
# OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
# PERFORMANCE OF THIS SOFTWARE.
# $Id: tests.sh,v 1.14 2007/06/19 23:47:05 tbox Exp $
# $Id: tests.sh,v 1.15 2011/11/02 08:17:01 marka Exp $
SYSTEMTESTTOP=..
. $SYSTEMTESTTOP/conf.sh
@@ -23,17 +23,29 @@ SYSTEMTESTTOP=..
status=0
echo "I:trying an axfr that should be denied (NOTAUTH)"
$DIG +tcp data.child.example. @10.53.0.3 axfr -p 5300 > dig.out.ns3 || status=1
grep "; Transfer failed." dig.out.ns3 > /dev/null || status=1
ret=0
$DIG +tcp data.child.example. @10.53.0.3 axfr -p 5300 > dig.out.ns3 || ret=1
grep "; Transfer failed." dig.out.ns3 > /dev/null || ret=1
[ $ret = 0 ] || { status=1; echo "I:failed"; }
echo "I:look for stub zone data without recursion (should not be found)"
$DIG +tcp +norec data.child.example. @10.53.0.3 txt -p 5300 > dig.out.ns3 \
|| status=1
$PERL ../digcomp.pl knowngood.dig.out.norec dig.out.ns3 || status=1
for i in 1 2 3 4 5 6 7 8 9
do
ret=0
$DIG +tcp +norec data.child.example. \
@10.53.0.3 txt -p 5300 > dig.out.ns3 || ret=1
grep "status: NOERROR" dig.out.ns3 > /dev/null || ret=1
[ $ret = 0 ] && break
sleep 1
done
$PERL ../digcomp.pl knowngood.dig.out.norec dig.out.ns3 || ret=1
[ $ret = 0 ] || { status=1; echo "I:failed"; }
echo "I:look for stub zone data with recursion (should be found)"
$DIG +tcp data.child.example. @10.53.0.3 txt -p 5300 > dig.out.ns3 || status=1
$PERL ../digcomp.pl knowngood.dig.out.rec dig.out.ns3 || status=1
ret=0
$DIG +tcp data.child.example. @10.53.0.3 txt -p 5300 > dig.out.ns3 || ret=1
$PERL ../digcomp.pl knowngood.dig.out.rec dig.out.ns3 || ret=1
[ $ret = 0 ] || { status=1; echo "I:failed"; }
echo "I:exit status: $status"
exit $status