diff options
author | Christian Grothoff <christian@grothoff.org> | 2023-09-11 15:33:01 +0200 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2023-09-11 15:33:01 +0200 |
commit | dae8235928105f24f3178cdd2bcfa67ac0fb21c3 (patch) | |
tree | db60f58b780d8dffd43e3408cb978e654f46eca8 /src/util/wallet_signatures.c | |
parent | 3b99f24648f477a2b7afd890657bb2675e211d31 (diff) | |
download | exchange-dae8235928105f24f3178cdd2bcfa67ac0fb21c3.tar.xz |
improve wallet_Data support in exchange APIs
Diffstat (limited to 'src/util/wallet_signatures.c')
-rw-r--r-- | src/util/wallet_signatures.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/util/wallet_signatures.c b/src/util/wallet_signatures.c index 89acecb35..4b2fab6e4 100644 --- a/src/util/wallet_signatures.c +++ b/src/util/wallet_signatures.c @@ -127,6 +127,7 @@ TALER_wallet_deposit_sign ( const struct TALER_Amount *deposit_fee, const struct TALER_MerchantWireHashP *h_wire, const struct TALER_PrivateContractHashP *h_contract_terms, + const struct GNUNET_HashCode *wallet_data_hash, const struct TALER_AgeCommitmentHash *h_age_commitment, const struct TALER_ExtensionPolicyHashP *h_policy, const struct TALER_DenominationHashP *h_denom_pub, @@ -147,6 +148,8 @@ TALER_wallet_deposit_sign ( .merchant = *merchant_pub }; + if (NULL != wallet_data_hash) + dr.wallet_data_hash = *wallet_data_hash; if (NULL != h_age_commitment) dr.h_age_commitment = *h_age_commitment; if (NULL != h_policy) @@ -167,6 +170,7 @@ TALER_wallet_deposit_verify ( const struct TALER_Amount *deposit_fee, const struct TALER_MerchantWireHashP *h_wire, const struct TALER_PrivateContractHashP *h_contract_terms, + const struct GNUNET_HashCode *wallet_data_hash, const struct TALER_AgeCommitmentHash *h_age_commitment, const struct TALER_ExtensionPolicyHashP *h_policy, const struct TALER_DenominationHashP *h_denom_pub, @@ -185,10 +189,10 @@ TALER_wallet_deposit_verify ( .wallet_timestamp = GNUNET_TIME_timestamp_hton (wallet_timestamp), .refund_deadline = GNUNET_TIME_timestamp_hton (refund_deadline), .merchant = *merchant_pub, - .h_age_commitment = {{{0}}}, - .h_policy = {{{0}}} }; + if (NULL != wallet_data_hash) + dr.wallet_data_hash = *wallet_data_hash; if (NULL != h_age_commitment) dr.h_age_commitment = *h_age_commitment; if (NULL != h_policy) |