diff options
author | Marcello Stanisci <stanisci.m@gmail.com> | 2018-06-08 17:55:15 +0200 |
---|---|---|
committer | Marcello Stanisci <stanisci.m@gmail.com> | 2018-06-08 17:55:15 +0200 |
commit | e78f7a8ffde872d94807cf1723ea717df576fb0b (patch) | |
tree | 3a4994acf49cbc5a68e1eeee9b3a143a025346a7 | |
parent | 4abab727954276e568699a861337370c5688522a (diff) | |
download | deployment-e78f7a8ffde872d94807cf1723ea717df576fb0b.tar.gz deployment-e78f7a8ffde872d94807cf1723ea717df576fb0b.tar.bz2 deployment-e78f7a8ffde872d94807cf1723ea717df576fb0b.zip |
Auditor denom signing.
Only attempt to sign denom keys _if_ any of
those got generated; recall: denom keys only
get generated when there is some gap between
the validity of the youngest key and the "lookahead_sign"
configuration timestamp.
-rwxr-xr-x | bin/taler-deployment-keyup | 21 |
1 files changed, 11 insertions, 10 deletions
diff --git a/bin/taler-deployment-keyup b/bin/taler-deployment-keyup index 8e8ff62..a05ad6c 100755 --- a/bin/taler-deployment-keyup +++ b/bin/taler-deployment-keyup @@ -14,20 +14,21 @@ if test -z $TALER_CONFIG_ENV; then fi auditor_request_dir=${HOME}/shared-data/exchange/auditor-request/ + mkdir -p $auditor_request_dir taler-exchange-keyup \ -m ${HOME}/shared-data/exchange/offline-keys/master.priv \ -o $auditor_request_dir/auditor_request -taler-auditor-sign \ - -u $TALER_ENV_URL_AUDITOR \ - -m $(taler-config -s exchange -o master_public_key) \ - -r "$auditor_request_dir/auditor_request" \ - -o "$(taler-config -s exchangedb -o auditor_base_dir -f)/$(date +%s%N)" \ - -c ${HOME}/.config/taler.conf - -if [[ 0 != $? ]]; then - echo Auditor signing not accomplished. -fi +# Checks whether any denom key was generated, and +# only sign it if so. +if [[ -s $auditor_request_dir/auditor_request ]]; then + echo "There key material for the auditor to sign" + taler-auditor-sign \ + -u $TALER_ENV_URL_AUDITOR \ + -m $(taler-config -s exchange -o master_public_key) \ + -r "$auditor_request_dir/auditor_request" \ + -o "$(taler-config -s exchangedb -o auditor_base_dir -f)/$(date +%s%N)" \ + -c ${HOME}/.config/taler.conf chmod -fR g+rw ${HOME}/shared-data |