X-Git-Url: http://mj.ucw.cz/gitweb/?a=blobdiff_plain;f=bin%2Fgenzone;h=6c7bffc3e9d1da4672dae41db845999f2186ca43;hb=8027861ea0c775a47af4ae6ae116b42b25a089ce;hp=0a647a985609b466ff81df62de0af6dea6204f3e;hpb=dd04a4d50eca47c8ce85bf75240331bcf27367f7;p=nsc-5.git diff --git a/bin/genzone b/bin/genzone index 0a647a9..6c7bffc 100755 --- a/bin/genzone +++ b/bin/genzone @@ -13,10 +13,10 @@ Z=$1 shift CURRENT_HASH=$($M4 -DHASHING m4/nsc.m4 "$@" | md5sum | cut -d " " -f1) -if [ -f keys/$Z.hash ] ; then - CURRENT_HASH=$CURRENT_HASH:$(cat keys/$Z.hash) - if [ -f keys/resign-stamp ] ; then - CURRENT_HASH=$CURRENT_HASH:$(stat -c '%Y' keys/resign-stamp) +if [ -f khash/$Z ] ; then + CURRENT_HASH=$CURRENT_HASH:$(cat khash/$Z) + if [ -f khash/resign-stamp ] ; then + CURRENT_HASH=$CURRENT_HASH:$(stat -c '%Y' khash/resign-stamp) fi fi @@ -27,7 +27,7 @@ if [ "X$CURRENT_HASH" = "X$PREV_HASH" ] ; then else $M4 -DVERS=ver/$Z m4/nsc.m4 "$@" >zone/$Z.new NEWVER="$(sed -e "s/^;;; VERSION: //; t; d" zone/$Z.new)" - if [ -f keys/$Z.hash ] ; then + if [ -f khash/$Z ] ; then if ! dnssec-signzone -a -d dss -g -K keys/$Z $SIGNZONE_OPTIONS -f zone/$Z.signed -o $Z -S -3 - zone/$Z.new &>zone/$Z.tmp ; then cat zone/$Z.tmp echo >&2 "FATAL: Signing failed"