Blame bin/tests/system/dlv/ns1/sign.sh

Packit Service ae04f2
#!/bin/sh
Packit Service ae04f2
#
Packit Service ae04f2
# Copyright (C) Internet Systems Consortium, Inc. ("ISC")
Packit Service ae04f2
#
Packit Service ae04f2
# This Source Code Form is subject to the terms of the Mozilla Public
Packit Service ae04f2
# License, v. 2.0. If a copy of the MPL was not distributed with this
Packit Service ae04f2
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
Packit Service ae04f2
#
Packit Service ae04f2
# See the COPYRIGHT file distributed with this work for additional
Packit Service ae04f2
# information regarding copyright ownership.
Packit Service ae04f2
Packit Service ae04f2
SYSTEMTESTTOP=../..
Packit Service ae04f2
. $SYSTEMTESTTOP/conf.sh
Packit Service ae04f2
Packit Service ae04f2
SYSTESTDIR=dlv
Packit Service ae04f2
Packit Service ae04f2
(cd ../ns2 && $SHELL -e ./sign.sh || exit 1)
Packit Service ae04f2
Packit Service ae04f2
echo_i "dlv/ns1/sign.sh"
Packit Service ae04f2
Packit Service ae04f2
zone=.
Packit Service ae04f2
infile=root.db.in
Packit Service ae04f2
zonefile=root.db
Packit Service ae04f2
outfile=root.signed
Packit Service ae04f2
Packit Service ae04f2
keyname1=`$KEYGEN -r $RANDFILE -a DSA -b 768 -n zone $zone 2> /dev/null`
Packit Service ae04f2
keyname2=`$KEYGEN -f KSK -r $RANDFILE -a DSA -b 768 -n zone $zone 2> /dev/null`
Packit Service ae04f2
Packit Service ae04f2
cat $infile $keyname1.key $keyname2.key >$zonefile
Packit Service ae04f2
Packit Service ae04f2
$SIGNER -r $RANDFILE -g -o $zone -f $outfile $zonefile > /dev/null 2> signer.err || cat signer.err
Packit Service ae04f2
Packit Service ae04f2
echo_i "signed $zone"
Packit Service ae04f2
Packit Service ae04f2
keyfile_to_trusted_keys $keyname2 > trusted.conf
Packit Service ae04f2
cp trusted.conf ../ns5
Packit Service ae04f2
cp trusted.conf ../ns7