aboutsummaryrefslogtreecommitdiff
path: root/src/util/offline_signatures.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2022-02-17 15:10:14 +0100
committerChristian Grothoff <christian@grothoff.org>2022-02-17 15:18:09 +0100
commita351bfc4b4ca15ce7fd998cf9691e85cf84dc426 (patch)
tree88ec3b739914739f05d4c8cae2a2af40d29ebf82 /src/util/offline_signatures.c
parent8bdf6ab19df70c16d335ecf82f2c3b2117eeb70e (diff)
downloadexchange-a351bfc4b4ca15ce7fd998cf9691e85cf84dc426.tar.xz
-fix CS nonce reuse check logic
Diffstat (limited to 'src/util/offline_signatures.c')
-rw-r--r--src/util/offline_signatures.c30
1 files changed, 6 insertions, 24 deletions
diff --git a/src/util/offline_signatures.c b/src/util/offline_signatures.c
index ab2988349..fa4b80fe2 100644
--- a/src/util/offline_signatures.c
+++ b/src/util/offline_signatures.c
@@ -255,10 +255,7 @@ TALER_exchange_offline_denom_validity_sign (
struct GNUNET_TIME_Timestamp stamp_expire_deposit,
struct GNUNET_TIME_Timestamp stamp_expire_legal,
const struct TALER_Amount *coin_value,
- const struct TALER_Amount *fee_withdraw,
- const struct TALER_Amount *fee_deposit,
- const struct TALER_Amount *fee_refresh,
- const struct TALER_Amount *fee_refund,
+ const struct TALER_DenomFeeSet *fees,
const struct TALER_MasterPrivateKeyP *master_priv,
struct TALER_MasterSignatureP *master_sig)
{
@@ -278,14 +275,8 @@ TALER_exchange_offline_denom_validity_sign (
&issue.master.eddsa_pub);
TALER_amount_hton (&issue.value,
coin_value);
- TALER_amount_hton (&issue.fee_withdraw,
- fee_withdraw);
- TALER_amount_hton (&issue.fee_deposit,
- fee_deposit);
- TALER_amount_hton (&issue.fee_refresh,
- fee_refresh);
- TALER_amount_hton (&issue.fee_refund,
- fee_refund);
+ TALER_denom_fee_set_hton (&issue.fees,
+ fees);
GNUNET_CRYPTO_eddsa_sign (&master_priv->eddsa_priv,
&issue,
&master_sig->eddsa_signature);
@@ -300,10 +291,7 @@ TALER_exchange_offline_denom_validity_verify (
struct GNUNET_TIME_Timestamp stamp_expire_deposit,
struct GNUNET_TIME_Timestamp stamp_expire_legal,
const struct TALER_Amount *coin_value,
- const struct TALER_Amount *fee_withdraw,
- const struct TALER_Amount *fee_deposit,
- const struct TALER_Amount *fee_refresh,
- const struct TALER_Amount *fee_refund,
+ const struct TALER_DenomFeeSet *fees,
const struct TALER_MasterPublicKeyP *master_pub,
const struct TALER_MasterSignatureP *master_sig)
{
@@ -321,14 +309,8 @@ TALER_exchange_offline_denom_validity_verify (
TALER_amount_hton (&dkv.value,
coin_value);
- TALER_amount_hton (&dkv.fee_withdraw,
- fee_withdraw);
- TALER_amount_hton (&dkv.fee_deposit,
- fee_deposit);
- TALER_amount_hton (&dkv.fee_refresh,
- fee_refresh);
- TALER_amount_hton (&dkv.fee_refund,
- fee_refund);
+ TALER_denom_fee_set_hton (&dkv.fees,
+ fees);
return
GNUNET_CRYPTO_eddsa_verify (
TALER_SIGNATURE_MASTER_DENOMINATION_KEY_VALIDITY,