]> git.ipfire.org Git - thirdparty/unbound.git/commitdiff
- Fix root_zonemd unit test, it checks that the root ZONEMD verifies,
authorW.C.A. Wijngaards <wouter@nlnetlabs.nl>
Fri, 8 Dec 2023 16:15:35 +0000 (17:15 +0100)
committerW.C.A. Wijngaards <wouter@nlnetlabs.nl>
Fri, 8 Dec 2023 16:15:35 +0000 (17:15 +0100)
  now that the root has a valid ZONEMD.

doc/Changelog
testdata/root_zonemd.tdir/root_zonemd.test

index 49668889cdd094fbb0257df7f04e7898af47efae..1c77e2d0b73a758612f5a7ec8103725d626910c0 100644 (file)
@@ -1,6 +1,8 @@
 8 December 2023: Yorgos
        - Merge PR #973: Use the origin (DNAME) TTL for synthesized CNAMEs as
          per RFC 6672.
+       - Fix root_zonemd unit test, it checks that the root ZONEMD verifies,
+         now that the root has a valid ZONEMD.
 
 7 December 2023: Wouter
        - Fix #974: doc: default number of outgoing ports without libevent.
index 0dfada1342176a1568be9639b23da720bcb07d9b..2745b5009e8f0ac21fcf451358a270d64a490289 100644 (file)
@@ -6,7 +6,7 @@
 
 PRE="../.."
 # do the test
-echo "> dig www.example.com."
+echo "> dig . SOA"
 dig @127.0.0.1 -p $UNBOUND_PORT . SOA | tee outfile
 echo "> check answer"
 if grep root-servers outfile | grep "nstld.verisign-grs.com"; then
@@ -26,7 +26,19 @@ else
 fi
 
 # This is the output when an unsupported algorithm is used.
-if grep "auth zone . ZONEMD unsupported algorithm" unbound.log; then
+if grep "auth zone . zonemd DNSSEC verification of SOA and ZONEMD RRsets secure" unbound.log; then
+       echo "OK"
+else
+       echo "ZONEMD verification not OK"
+       exit 1
+fi
+if grep "auth-zone . ZONEMD hash is correct" unbound.log; then
+       echo "OK"
+else
+       echo "ZONEMD verification not OK"
+       exit 1
+fi
+if grep "auth zone . ZONEMD verification successful" unbound.log; then
        echo "OK"
 else
        echo "ZONEMD verification not OK"
@@ -40,12 +52,12 @@ if test $? -ne 0; then
        exit 1
 fi
 # The output of the reload can be checked.
-#echo "> check unbound-control output"
-#if grep "example.com: ZONEMD verification successful" outfile; then
-       #echo "OK"
-#else
-       #echo "Not OK"
-       #exit 1
-#fi
+echo "> check unbound-control output"
+if grep ".: ZONEMD verification successful" outfile; then
+       echo "OK"
+else
+       echo "Not OK"
+       exit 1
+fi
 
 exit 0