]> granicus.if.org Git - pdns/commitdiff
testing scripts
authorBert Hubert <bert.hubert@netherlabs.nl>
Tue, 28 Dec 2010 14:08:08 +0000 (14:08 +0000)
committerBert Hubert <bert.hubert@netherlabs.nl>
Tue, 28 Dec 2010 14:08:08 +0000 (14:08 +0000)
git-svn-id: svn://svn.powerdns.com/pdns/trunk/pdns@1764 d19b8d6e-7fed-0310-83ef-9ca221ded41b

pdns/dnssec-scripts/clone-zone [new file with mode: 0755]

diff --git a/pdns/dnssec-scripts/clone-zone b/pdns/dnssec-scripts/clone-zone
new file mode 100755 (executable)
index 0000000..b27d2b1
--- /dev/null
@@ -0,0 +1,11 @@
+#!/bin/bash
+
+TIMERANGE=$(drill -D @127.0.0.1 -p 5300 powerdnssec.org -t soa | grep RRSIG | head -1 | 
+       awk '{printf "-i %s -e %s", $9, $10}')
+
+PLAINZONE=$1
+ZSKID=$(drill -D @127.0.0.1 -p 5300 powerdnssec.org -t soa  | grep RRSIG | cut -f2 -d{ | cut -f1 -d} | awk '{print $3}')
+ZSKFNAME=$(echo /home/ahu/work/pdns/pdns/pdns/keys/$1/keys/*$ZSKID*zsk.active.private | sed s/.private//)
+
+ldns-signzone $2 $1 $TIMERANGE $ZSKFNAME
+echo Zone signed with key id $ZSKID now in $1.signed
\ No newline at end of file