sign.sh revision 1.1.1.3
1#!/bin/sh -e
2#
3# Copyright (C) Internet Systems Consortium, Inc. ("ISC")
4#
5# This Source Code Form is subject to the terms of the Mozilla Public
6# License, v. 2.0. If a copy of the MPL was not distributed with this
7# file, You can obtain one at http://mozilla.org/MPL/2.0/.
8#
9# See the COPYRIGHT file distributed with this work for additional
10# information regarding copyright ownership.
11
12SYSTEMTESTTOP=../..
13. $SYSTEMTESTTOP/conf.sh
14
15zone=.
16infile=root.db.in
17zonefile=root.db
18
19key1=`$KEYGEN -q -a ECDSAP256SHA256 -n zone $zone`
20key2=`$KEYGEN -q -a ECDSAP384SHA384 -n zone -f KSK $zone`
21$DSFROMKEY -a sha-384 $key2.key > dsset-384
22
23cat $infile $key1.key $key2.key > $zonefile
24
25$SIGNER -P -g -o $zone $zonefile > /dev/null 2> signer.err || cat signer.err
26
27# Configure the resolving server with a static key.
28keyfile_to_static_ds $key1 > trusted.conf
29cp trusted.conf ../ns2/trusted.conf
30