Remove building with NOCRYPTO option
[minix.git] / external / bsd / bind / dist / bin / tests / system / metadata / setup.sh
blob9b82595f63dd78de22265381f95f052ca1683a66
1 #!/bin/sh -e
3 # Copyright (C) 2009, 2011, 2012, 2014 Internet Systems Consortium, Inc. ("ISC")
5 # Permission to use, copy, modify, and/or distribute this software for any
6 # purpose with or without fee is hereby granted, provided that the above
7 # copyright notice and this permission notice appear in all copies.
9 # THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
10 # REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
11 # AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
12 # INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
13 # LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
14 # OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
15 # PERFORMANCE OF THIS SOFTWARE.
17 SYSTEMTESTTOP=..
18 . $SYSTEMTESTTOP/conf.sh
20 $SHELL ./clean.sh
22 test -r $RANDFILE || $GENRANDOM 400 $RANDFILE
24 pzone=parent.nil
25 czone=child.parent.nil
27 echo "I:generating keys"
29 # active zsk
30 zsk=`$KEYGEN -q -r $RANDFILE $czone`
31 echo $zsk > zsk.key
33 # not yet published or active
34 pending=`$KEYGEN -q -r $RANDFILE -P none -A none $czone`
35 echo $pending > pending.key
37 # published but not active
38 standby=`$KEYGEN -q -r $RANDFILE -A none $czone`
39 echo $standby > standby.key
41 # inactive
42 inact=`$KEYGEN -q -r $RANDFILE -P now-24h -A now-24h -I now $czone`
43 echo $inact > inact.key
45 # active ksk
46 ksk=`$KEYGEN -q -r $RANDFILE -fk $czone`
47 echo $ksk > ksk.key
49 # published but not YET active; will be active in 15 seconds
50 rolling=`$KEYGEN -q -r $RANDFILE -fk $czone`
51 $SETTIME -A now+15s $rolling > /dev/null
52 echo $rolling > rolling.key
54 # revoked
55 revoke1=`$KEYGEN -q -r $RANDFILE -fk $czone`
56 echo $revoke1 > prerev.key
57 revoke2=`$REVOKE $revoke1`
58 echo $revoke2 | sed -e 's#\./##' -e "s/\.key.*$//" > postrev.key
60 pzsk=`$KEYGEN -q -r $RANDFILE $pzone`
61 echo $pzsk > parent.zsk.key
63 pksk=`$KEYGEN -q -r $RANDFILE -fk $pzone`
64 echo $pksk > parent.ksk.key
66 oldstyle=`$KEYGEN -Cq -r $RANDFILE $pzone`
67 echo $oldstyle > oldstyle.key