added system tests
This commit is contained in:
15
bin/tests/system/dnssec/ns3/insecure.example.db
Normal file
15
bin/tests/system/dnssec/ns3/insecure.example.db
Normal file
@@ -0,0 +1,15 @@
|
||||
$TTL 300 ; 5 minutes
|
||||
@ IN SOA mname1. . (
|
||||
2000042407 ; serial
|
||||
20 ; refresh (20 seconds)
|
||||
20 ; retry (20 seconds)
|
||||
1814400 ; expire (3 weeks)
|
||||
3600 ; minimum (1 hour)
|
||||
)
|
||||
NS ns
|
||||
ns A 10.53.0.3
|
||||
|
||||
a A 10.0.0.1
|
||||
b A 10.0.0.2
|
||||
d A 10.0.0.4
|
||||
z A 10.0.0.26
|
||||
24
bin/tests/system/dnssec/ns3/named.conf
Normal file
24
bin/tests/system/dnssec/ns3/named.conf
Normal file
@@ -0,0 +1,24 @@
|
||||
options {
|
||||
pid-file "named.pid";
|
||||
listen-on { 10.53.0.3; };
|
||||
recursion no;
|
||||
notify yes;
|
||||
};
|
||||
|
||||
zone "." {
|
||||
type hint;
|
||||
file "root.hint";
|
||||
};
|
||||
|
||||
zone "secure.example" {
|
||||
type master;
|
||||
file "secure.example.db.signed";
|
||||
allow-update { any; };
|
||||
};
|
||||
|
||||
zone "insecure.example" {
|
||||
type master;
|
||||
file "insecure.example.db";
|
||||
allow-update { any; };
|
||||
};
|
||||
|
||||
3
bin/tests/system/dnssec/ns3/root.hint
Normal file
3
bin/tests/system/dnssec/ns3/root.hint
Normal file
@@ -0,0 +1,3 @@
|
||||
$TTL 999999
|
||||
. IN NS a.root-servers.nil.
|
||||
a.root-servers.nil. IN A 10.53.0.1
|
||||
15
bin/tests/system/dnssec/ns3/secure.example.db.in
Normal file
15
bin/tests/system/dnssec/ns3/secure.example.db.in
Normal file
@@ -0,0 +1,15 @@
|
||||
$TTL 300 ; 5 minutes
|
||||
@ IN SOA mname1. . (
|
||||
2000042407 ; serial
|
||||
20 ; refresh (20 seconds)
|
||||
20 ; retry (20 seconds)
|
||||
1814400 ; expire (3 weeks)
|
||||
3600 ; minimum (1 hour)
|
||||
)
|
||||
NS ns
|
||||
ns A 10.53.0.3
|
||||
|
||||
a A 10.0.0.1
|
||||
b A 10.0.0.2
|
||||
d A 10.0.0.4
|
||||
z A 10.0.0.26
|
||||
24
bin/tests/system/dnssec/ns3/sign.sh
Normal file
24
bin/tests/system/dnssec/ns3/sign.sh
Normal file
@@ -0,0 +1,24 @@
|
||||
#!/bin/sh
|
||||
|
||||
zone=secure.example.
|
||||
infile=secure.example.db.in
|
||||
zonefile=secure.example.db
|
||||
|
||||
rm -f K$zone*.key
|
||||
rm -f K$zone*.private
|
||||
rm -f $zone*.keyset
|
||||
|
||||
keyname=`$KEYGEN -a RSA -b 768 -n zone $zone`
|
||||
|
||||
tag=`echo $keykname | sed -n 's/^.*\+\([0-9][0-9]*\)$/\1/p'`
|
||||
|
||||
echo "key=$keyname, tag=$tag"
|
||||
|
||||
pubkeyfile="$keyname.key"
|
||||
|
||||
$KEYSETTOOL $zone $tag/001
|
||||
|
||||
cat $infile $pubkeyfile >$zonefile
|
||||
|
||||
$SIGNER -v 1 -o $zone $zonefile
|
||||
|
||||
Reference in New Issue
Block a user