]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
Wait a little bit longer for autosign, bail out on not enough categories
authorOndřej Surý <ondrej@sury.org>
Fri, 8 Nov 2019 06:43:33 +0000 (07:43 +0100)
committerOndřej Surý <ondrej@sury.org>
Fri, 8 Nov 2019 06:43:33 +0000 (07:43 +0100)
bin/tests/system/autosign/tests.sh

index 9641bcab424f1f97f8051b01f556aa964dc0976c..cd2a7dce39a399b1defd0a0af133e4282635b72c 100755 (executable)
@@ -79,6 +79,7 @@ checkjitter () {
        done
        if [ "$_count" -lt 8 ]; then
                echo_i "error: not enough categories"
+               return 1
        fi
 
        # Calculate mean
@@ -1026,13 +1027,15 @@ $KEYGEN -a rsasha1 -3 -q -K ns3 jitter.nsec3.example > /dev/null
 # Trigger zone signing.
 $RNDCCMD 10.53.0.3 sign jitter.nsec3.example. 2>&1 | sed 's/^/ns3 /' | cat_i
 # Wait until zone has been signed.
-for i in 0 1 2 3 4 5 6 7 8 9; do
+i=0
+while [ "$i" -lt 20 ]; do
        failed=0
        $DIG $DIGOPTS axfr jitter.nsec3.example @10.53.0.3 > dig.out.ns3.test$n || failed=1
        grep "NSEC3PARAM" dig.out.ns3.test$n > /dev/null || failed=1
        [ $failed -eq 0 ] && break
        echo_i "waiting ... ($i)"
-       sleep 2
+       sleep $((i/5))
+       i=$((i+1))
 done
 [ $failed != 0 ] && echo_i "error: no NSEC3PARAM found in AXFR" && ret=1
 # Check jitter distribution.