From ea648e70a989cca190cd7403fe892fd2dcc290b4 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Sun, 5 May 2024 20:37:14 +0200 Subject: Adding upstream version 1:9.11.5.P4+dfsg. Signed-off-by: Daniel Baumann --- bin/tests/system/staticstub/ns3/example.db.in | 30 ++++++++++++++++ bin/tests/system/staticstub/ns3/example.org.db | 22 ++++++++++++ bin/tests/system/staticstub/ns3/named.conf.in | 43 +++++++++++++++++++++++ bin/tests/system/staticstub/ns3/sign.sh | 42 ++++++++++++++++++++++ bin/tests/system/staticstub/ns3/undelegated.db.in | 21 +++++++++++ 5 files changed, 158 insertions(+) create mode 100644 bin/tests/system/staticstub/ns3/example.db.in create mode 100644 bin/tests/system/staticstub/ns3/example.org.db create mode 100644 bin/tests/system/staticstub/ns3/named.conf.in create mode 100755 bin/tests/system/staticstub/ns3/sign.sh create mode 100644 bin/tests/system/staticstub/ns3/undelegated.db.in (limited to 'bin/tests/system/staticstub/ns3') diff --git a/bin/tests/system/staticstub/ns3/example.db.in b/bin/tests/system/staticstub/ns3/example.db.in new file mode 100644 index 0000000..85fc1d8 --- /dev/null +++ b/bin/tests/system/staticstub/ns3/example.db.in @@ -0,0 +1,30 @@ +; 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. + +$ORIGIN . +$TTL 300 ; 5 minutes +example IN SOA ns3.example. hostmaster.example. ( + 2010080900 ; serial + 20 ; refresh (20 seconds) + 20 ; retry (20 seconds) + 1814400 ; expire (3 weeks) + 3600 ; minimum (1 hour) + ) +example. NS ns4.example. ; fake +example. A 10.53.0.4 ; fake +example. AAAA ::1 ; fake + +ns4.example. A 10.53.0.4 +data.example. TXT "some" "test" "data" +data2.example. TXT "2nd test data" +data3.example. TXT "3rd test data" +data4.example. TXT "4th test data" + +sub.example. NS ns.sub.example. +ns.sub.example. A 10.53.0.4 diff --git a/bin/tests/system/staticstub/ns3/example.org.db b/bin/tests/system/staticstub/ns3/example.org.db new file mode 100644 index 0000000..becf883 --- /dev/null +++ b/bin/tests/system/staticstub/ns3/example.org.db @@ -0,0 +1,22 @@ +; 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. + +$ORIGIN . +$TTL 300 ; 5 minutes +example.org IN SOA ns.example.org. hostmaster.example.org. ( + 2010080906 ; serial + 20 ; refresh (20 seconds) + 20 ; retry (20 seconds) + 1814400 ; expire (3 weeks) + 3600 ; minimum (1 hour) + ) +example.org. NS ns.example.org. +ns.example.org. A 10.53.0.3 + +data.example.org. TXT "example org data" diff --git a/bin/tests/system/staticstub/ns3/named.conf.in b/bin/tests/system/staticstub/ns3/named.conf.in new file mode 100644 index 0000000..b582196 --- /dev/null +++ b/bin/tests/system/staticstub/ns3/named.conf.in @@ -0,0 +1,43 @@ +/* + * 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. + */ + +key rndc_key { + secret "1234abcd8765"; + algorithm hmac-sha256; +}; + +controls { + inet 10.53.0.3 port @CONTROLPORT@ allow { any; } keys { rndc_key; }; +}; + +options { + query-source address 10.53.0.3; + notify-source 10.53.0.3; + transfer-source 10.53.0.3; + port @PORT@; + pid-file "named.pid"; + listen-on { 10.53.0.3; }; + listen-on-v6 { none; }; + recursion no; + notify no; +}; + +EXAMPLE_ZONE_PLACEHOLDER + +zone "example.org" { + type master; + file "example.org.db"; +}; + +zone "undelegated" { + type master; + file "undelegated.db.signed"; +}; diff --git a/bin/tests/system/staticstub/ns3/sign.sh b/bin/tests/system/staticstub/ns3/sign.sh new file mode 100755 index 0000000..32af7d0 --- /dev/null +++ b/bin/tests/system/staticstub/ns3/sign.sh @@ -0,0 +1,42 @@ +#!/bin/sh +# +# 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. + +SYSTEMTESTTOP=../.. +. $SYSTEMTESTTOP/conf.sh + +zone=example. +infile=example.db.in +zonefile=example.db + +(cd ../ns4 && $SHELL -e sign.sh ) + +cp ../ns4/dsset-sub.example$TP . + +keyname1=`$KEYGEN -q -r $RANDFILE -a RSASHA256 -b 1024 -n zone $zone` +keyname2=`$KEYGEN -q -r $RANDFILE -a RSASHA256 -b 2048 -f KSK -n zone $zone` +cat $infile $keyname1.key $keyname2.key > $zonefile + +$SIGNER -g -r $RANDFILE -o $zone $zonefile > /dev/null 2>&1 + +# Configure the resolving server with a trusted key. +keyfile_to_trusted_keys $keyname2 > trusted.conf + +zone=undelegated +infile=undelegated.db.in +zonefile=undelegated.db +keyname1=`$KEYGEN -q -r $RANDFILE -a RSASHA256 -b 1024 -n zone $zone` +keyname2=`$KEYGEN -q -r $RANDFILE -a RSASHA256 -b 2048 -f KSK -n zone $zone` +cat $infile $keyname1.key $keyname2.key > $zonefile + +$SIGNER -g -r $RANDFILE -o $zone $zonefile > /dev/null 2>&1 + +keyfile_to_trusted_keys $keyname2 >> trusted.conf +cp trusted.conf ../ns2/trusted.conf diff --git a/bin/tests/system/staticstub/ns3/undelegated.db.in b/bin/tests/system/staticstub/ns3/undelegated.db.in new file mode 100644 index 0000000..c85337d --- /dev/null +++ b/bin/tests/system/staticstub/ns3/undelegated.db.in @@ -0,0 +1,21 @@ +; 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. + +$TTL 300 ; 5 minutes +undelegated. IN SOA ns3.undelegated. hostmaster.undelegated. ( + 2010080900 ; serial + 20 ; refresh (20 seconds) + 20 ; retry (20 seconds) + 1814400 ; expire (3 weeks) + 3600 ; minimum (1 hour) + ) +undelegated. NS ns3.undelegated. +undelegated. A 10.53.0.4 +undelegated. AAAA ::1 +ns3.undelegated. A 10.53.0.3 -- cgit v1.2.3