From 00fa7483b9151b4c8db23aa2e24129b167747374 Mon Sep 17 00:00:00 2001 From: Matthijs Mekking Date: Wed, 22 Nov 2023 08:43:50 +0100 Subject: [PATCH] Renumber the ns2/named-alt*.conf.in files Now that some configuration input files have been removed, rename the filenames. --- .../{named-alt7.conf.in => named-alt1.conf.in} | 4 +++- .../{named-alt5.conf.in => named-alt2.conf.in} | 0 .../{named-alt6.conf.in => named-alt3.conf.in} | 0 .../system/runtime/ns2/named-alt4.conf.in | 4 +--- bin/tests/system/runtime/setup.sh | 6 +++--- bin/tests/system/runtime/tests.sh | 18 +++++++++--------- 6 files changed, 16 insertions(+), 16 deletions(-) rename bin/tests/system/runtime/ns2/{named-alt7.conf.in => named-alt1.conf.in} (89%) rename bin/tests/system/runtime/ns2/{named-alt5.conf.in => named-alt2.conf.in} (100%) rename bin/tests/system/runtime/ns2/{named-alt6.conf.in => named-alt3.conf.in} (100%) diff --git a/bin/tests/system/runtime/ns2/named-alt7.conf.in b/bin/tests/system/runtime/ns2/named-alt1.conf.in similarity index 89% rename from bin/tests/system/runtime/ns2/named-alt7.conf.in rename to bin/tests/system/runtime/ns2/named-alt1.conf.in index 722316f725..4c0312acd5 100644 --- a/bin/tests/system/runtime/ns2/named-alt7.conf.in +++ b/bin/tests/system/runtime/ns2/named-alt1.conf.in @@ -12,9 +12,11 @@ */ options { + directory "./nope"; port @PORT@; pid-file "named.pid"; listen-on { 10.53.0.2; }; - listen-on-v6 { fd92:7065:b8e:ffff::2; }; + listen-on-v6 { none; }; + recursion no; dnssec-validation no; }; diff --git a/bin/tests/system/runtime/ns2/named-alt5.conf.in b/bin/tests/system/runtime/ns2/named-alt2.conf.in similarity index 100% rename from bin/tests/system/runtime/ns2/named-alt5.conf.in rename to bin/tests/system/runtime/ns2/named-alt2.conf.in diff --git a/bin/tests/system/runtime/ns2/named-alt6.conf.in b/bin/tests/system/runtime/ns2/named-alt3.conf.in similarity index 100% rename from bin/tests/system/runtime/ns2/named-alt6.conf.in rename to bin/tests/system/runtime/ns2/named-alt3.conf.in diff --git a/bin/tests/system/runtime/ns2/named-alt4.conf.in b/bin/tests/system/runtime/ns2/named-alt4.conf.in index 4c0312acd5..722316f725 100644 --- a/bin/tests/system/runtime/ns2/named-alt4.conf.in +++ b/bin/tests/system/runtime/ns2/named-alt4.conf.in @@ -12,11 +12,9 @@ */ options { - directory "./nope"; port @PORT@; pid-file "named.pid"; listen-on { 10.53.0.2; }; - listen-on-v6 { none; }; - recursion no; + listen-on-v6 { fd92:7065:b8e:ffff::2; }; dnssec-validation no; }; diff --git a/bin/tests/system/runtime/setup.sh b/bin/tests/system/runtime/setup.sh index ce9c789cca..98702fdabb 100644 --- a/bin/tests/system/runtime/setup.sh +++ b/bin/tests/system/runtime/setup.sh @@ -17,10 +17,10 @@ $SHELL clean.sh copy_setports ns2/named1.conf.in ns2/named.conf +copy_setports ns2/named-alt1.conf.in ns2/named-alt1.conf +copy_setports ns2/named-alt2.conf.in ns2/named-alt2.conf +copy_setports ns2/named-alt3.conf.in ns2/named-alt3.conf copy_setports ns2/named-alt4.conf.in ns2/named-alt4.conf -copy_setports ns2/named-alt5.conf.in ns2/named-alt5.conf -copy_setports ns2/named-alt6.conf.in ns2/named-alt6.conf -copy_setports ns2/named-alt7.conf.in ns2/named-alt7.conf mkdir ns2/nope chmod 555 ns2/nope diff --git a/bin/tests/system/runtime/tests.sh b/bin/tests/system/runtime/tests.sh index dec61dc546..edddc08934 100644 --- a/bin/tests/system/runtime/tests.sh +++ b/bin/tests/system/runtime/tests.sh @@ -80,7 +80,7 @@ status=$((status + ret)) n=$((n + 1)) echo_i "checking that named refuses to reconfigure if working directory is not writable ($n)" ret=0 -copy_setports ns2/named-alt4.conf.in ns2/named.conf +copy_setports ns2/named-alt1.conf.in ns2/named.conf $RNDCCMD 10.53.0.2 reconfig >rndc.out.$n 2>&1 && ret=1 grep "failed: permission denied" rndc.out.$n >/dev/null 2>&1 || ret=1 sleep 1 @@ -91,7 +91,7 @@ status=$((status + ret)) n=$((n + 1)) echo_i "checking that named refuses to reconfigure if managed-keys-directory is not writable ($n)" ret=0 -copy_setports ns2/named-alt5.conf.in ns2/named.conf +copy_setports ns2/named-alt2.conf.in ns2/named.conf $RNDCCMD 10.53.0.2 reconfig >rndc.out.$n 2>&1 && ret=1 grep "failed: permission denied" rndc.out.$n >/dev/null 2>&1 || ret=1 sleep 1 @@ -102,7 +102,7 @@ status=$((status + ret)) n=$((n + 1)) echo_i "checking that named refuses to reconfigure if new-zones-directory is not writable ($n)" ret=0 -copy_setports ns2/named-alt6.conf.in ns2/named.conf +copy_setports ns2/named-alt3.conf.in ns2/named.conf $RNDCCMD 10.53.0.2 reconfig >rndc.out.$n 2>&1 && ret=1 grep "failed: permission denied" rndc.out.$n >/dev/null 2>&1 || ret=1 sleep 1 @@ -123,7 +123,7 @@ status=$((status + ret)) n=$((n + 1)) echo_i "checking that named refuses to start if working directory is not writable ($n)" ret=0 -testpid=$(run_named ns2 named$n.run -c named-alt4.conf -D runtime-ns2-extra-4) +testpid=$(run_named ns2 named$n.run -c named-alt1.conf -D runtime-ns2-extra-4) test -n "$testpid" || ret=1 retry_quiet 10 check_named_log "exiting (due to fatal error)" ns2/named$n.run || ret=1 grep "[^-]directory './nope' is not writable" ns2/named$n.run >/dev/null 2>&1 || ret=1 @@ -135,7 +135,7 @@ status=$((status + ret)) n=$((n + 1)) echo_i "checking that named refuses to start if managed-keys-directory is not writable ($n)" ret=0 -testpid=$(run_named ns2 named$n.run -c named-alt5.conf -D runtime-ns2-extra-5) +testpid=$(run_named ns2 named$n.run -c named-alt2.conf -D runtime-ns2-extra-5) test -n "$testpid" || ret=1 retry_quiet 10 check_named_log "exiting (due to fatal error)" ns2/named$n.run || ret=1 grep "managed-keys-directory './nope' is not writable" ns2/named$n.run >/dev/null 2>&1 || ret=1 @@ -147,7 +147,7 @@ status=$((status + ret)) n=$((n + 1)) echo_i "checking that named refuses to start if new-zones-directory is not writable ($n)" ret=0 -testpid=$(run_named ns2 named$n.run -c named-alt6.conf -D runtime-ns2-extra-6) +testpid=$(run_named ns2 named$n.run -c named-alt3.conf -D runtime-ns2-extra-6) test -n "$testpid" || ret=1 retry_quiet 10 check_named_log "exiting (due to fatal error)" ns2/named$n.run || ret=1 grep "new-zones-directory './nope' is not writable" ns2/named$n.run >/dev/null 2>&1 || ret=1 @@ -160,7 +160,7 @@ n=$((n + 1)) echo_i "checking that named logs control characters in octal notation ($n)" ret=0 INSTANCE_NAME="runtime-ns2-extra-7-$(cat ctrl-chars)" -testpid=$(run_named ns2 named$n.run -c named-alt7.conf -D "${INSTANCE_NAME}") +testpid=$(run_named ns2 named$n.run -c named-alt4.conf -D "${INSTANCE_NAME}") test -n "$testpid" || ret=1 retry_quiet 60 check_named_log "running$" ns2/named$n.run || ret=1 grep 'running as.*\\177\\033' ns2/named$n.run >/dev/null || ret=1 @@ -173,7 +173,7 @@ n=$((n + 1)) echo_i "checking that named escapes special characters in the logs ($n)" ret=0 INSTANCE_NAME="runtime-ns2-extra-8-$;" -testpid=$(run_named ns2 named$n.run -c named-alt7.conf -D "${INSTANCE_NAME}") +testpid=$(run_named ns2 named$n.run -c named-alt4.conf -D "${INSTANCE_NAME}") test -n "$testpid" || ret=1 retry_quiet 60 check_named_log "running$" ns2/named$n.run || ret=1 grep 'running as.*\\$\\;' ns2/named$n.run >/dev/null || ret=1 @@ -187,7 +187,7 @@ echo_i "checking that named logs an ellipsis when the command line is larger tha ret=0 LONG_CMD_LINE=$(cat long-cmd-line) # shellcheck disable=SC2086 -testpid=$(run_named ns2 named$n.run $LONG_CMD_LINE -c "named-alt7.conf") +testpid=$(run_named ns2 named$n.run $LONG_CMD_LINE -c "named-alt4.conf") test -n "$testpid" || ret=1 retry_quiet 60 check_named_log "running$" ns2/named$n.run || ret=1 grep "running as.*\.\.\.$" ns2/named$n.run >/dev/null || ret=1