From 0db5b087ed2d5bedfe5ef09ad9ea0fa347eeb18b Mon Sep 17 00:00:00 2001 From: Mark Andrews Date: Thu, 3 May 2018 16:50:32 +1000 Subject: [PATCH] add duplicate signature test --- bin/tests/system/conf.sh.in | 4 +- bin/tests/system/conf.sh.win32 | 3 +- bin/tests/system/dupsigs/check_journal.pl | 209 ++++++++++++++++++ bin/tests/system/dupsigs/clean.sh | 19 ++ bin/tests/system/dupsigs/ns1/named.args | 1 + bin/tests/system/dupsigs/ns1/named.conf.in | 31 +++ bin/tests/system/dupsigs/ns1/reset_keys.sh | 97 ++++++++ .../system/dupsigs/ns1/signing.test.db.in | 16 ++ bin/tests/system/dupsigs/prereq.sh | 15 ++ bin/tests/system/dupsigs/setup.sh | 20 ++ bin/tests/system/dupsigs/tests.sh | 35 +++ util/copyrights | 9 + 12 files changed, 456 insertions(+), 3 deletions(-) create mode 100644 bin/tests/system/dupsigs/check_journal.pl create mode 100644 bin/tests/system/dupsigs/clean.sh create mode 100644 bin/tests/system/dupsigs/ns1/named.args create mode 100644 bin/tests/system/dupsigs/ns1/named.conf.in create mode 100644 bin/tests/system/dupsigs/ns1/reset_keys.sh create mode 100644 bin/tests/system/dupsigs/ns1/signing.test.db.in create mode 100644 bin/tests/system/dupsigs/prereq.sh create mode 100644 bin/tests/system/dupsigs/setup.sh create mode 100644 bin/tests/system/dupsigs/tests.sh diff --git a/bin/tests/system/conf.sh.in b/bin/tests/system/conf.sh.in index 5518c7918f..e4d60eaa18 100644 --- a/bin/tests/system/conf.sh.in +++ b/bin/tests/system/conf.sh.in @@ -71,8 +71,8 @@ KRB5_CONFIG=/dev/null # The "stress" test is not run by default since it creates enough # load on the machine to make it unusable to other users. -# The "dialup" and "delzone" tests are also not run by default because -# they take a very long time to complete. +# The "dialup", "delzone", and "dupsigs" tests are also not run by +# default because they take a very long time to complete. # # List of tests hard-coded to use ports 5300 and 9953. For this # reason, these must be run sequentially. diff --git a/bin/tests/system/conf.sh.win32 b/bin/tests/system/conf.sh.win32 index 4da318fca8..6bfac1357c 100644 --- a/bin/tests/system/conf.sh.win32 +++ b/bin/tests/system/conf.sh.win32 @@ -77,7 +77,8 @@ KRB5_CONFIG=NUL # The "stress" test is not run by default since it creates enough # load on the machine to make it unusable to other users. -# v6synth +# The "dialup", "delzone", and "dupsigs" tests are also not run by +# default because they take a very long time to complete. # # List of tests that use ports 5300 and 9953. For this reason, these must # be run sequentially. diff --git a/bin/tests/system/dupsigs/check_journal.pl b/bin/tests/system/dupsigs/check_journal.pl new file mode 100644 index 0000000000..972ea8b008 --- /dev/null +++ b/bin/tests/system/dupsigs/check_journal.pl @@ -0,0 +1,209 @@ +#!/usr/bin/env perl +# +# Copyright (C) Internet Systems Consortium, Inc. ("ISC") +# +# This Source Code Form is subject to the terms of the Mozilla Public +# License, v. 2.0. If a copy of the MPL was not distributed with this +# file, You can obtain one at http://mozilla.org/MPL/2.0/. +# +# See the COPYRIGHT file distributed with this work for additional +# information regarding copyright ownership. + +use strict; +use warnings; + +sub process_changeset; + +my @changeset; + +while( my $line = <> ) { + chomp $line; + + if( $line =~ /^(?add|del) (?