From 6fcbf2bc54aadec338184957f92452cadb8fa421 Mon Sep 17 00:00:00 2001 From: Mark Andrews Date: Mon, 25 Aug 2025 11:19:37 +1000 Subject: [PATCH] Add non canonical form entry to trigger log message (cherry picked from commit 76db9e276f5180c41dd8492a08b1396377903973) --- bin/tests/system/rpz/test2 | 4 ++++ bin/tests/system/rpz/tests.sh | 2 ++ 2 files changed, 6 insertions(+) diff --git a/bin/tests/system/rpz/test2 b/bin/tests/system/rpz/test2 index ad71e3ae56..8ef4296c96 100644 --- a/bin/tests/system/rpz/test2 +++ b/bin/tests/system/rpz/test2 @@ -51,7 +51,11 @@ update add 32.2.5.168.192.rpz-ip.bl 300 A 127.0.0.2 ; prefer first conflicting IP zone for a5-3.tld2 ; 12 update add 32.3.5.168.192.rpz-ip.bl 300 A 127.0.0.1 +; non canonical form entry to trigger log message +update add 128.2.0.0.0.0.3.2.2001.rpz-ip.bl 300 CNAME . send + +; update add 32.3.5.168.192.rpz-ip.bl-2 300 A 127.0.0.2 send diff --git a/bin/tests/system/rpz/tests.sh b/bin/tests/system/rpz/tests.sh index 70591d1060..e16d46d274 100644 --- a/bin/tests/system/rpz/tests.sh +++ b/bin/tests/system/rpz/tests.sh @@ -571,6 +571,8 @@ ckstats $ns5 test1 ns5 0 ckstats $ns6 test1 ns6 0 start_group "IP rewrites" test2 +msg='rpz IP address "128.2.0.0.0.0.3.2.2001" is not the canonical "128.2.zz.3.2.2001"' +grep "$msg" ns3/named.run >/dev/null || setret "expected 'is not the canonical' message not logged" nodata a3-1.tld2 # 1 NODATA nochange a3-2.tld2 # 2 no policy record so no change nochange a4-1.tld2 # 3 obsolete PASSTHRU record style