aboutsummaryrefslogtreecommitdiff
path: root/contrib/taler-exchange-revoke
blob: 8e4bc6ed4a48ed54cf7b2cf559bcb4c401fa5bae (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#!/bin/sh
# This file is in the public domain
#
# Used to first revoke a key and then restart the exchange
# to ensure it notices the revocation.
#
# Takes 2 arguments:
# $1: the configuration file name
# $2: the denomination key hash (DKH) of the denomination to revoke

set -eu

if [ "$#" -ne 2 ];
then
  echo "illegal number of parameters"
  exit 1
fi

taler-exchange-keyup -c $1 -r $2

EXCHANGE_PID=`ps x | grep taler-exchange-httpd | awk '{print $1}'`
kill -SIGUSR1 $EXCHANGE_PID

exit 0