From 97dfbec0811b1a0b92618f195e228c43376e4828 Mon Sep 17 00:00:00 2001 From: Christian Grothoff Date: Wed, 8 Jul 2020 15:46:51 +0200 Subject: add h_denom_pub to deposit signatures --- src/include/taler_exchange_service.h | 2 ++ src/include/taler_exchangedb_plugin.h | 15 +++++++++++++++ src/include/taler_signatures.h | 11 +++++++++++ 3 files changed, 28 insertions(+) (limited to 'src/include') diff --git a/src/include/taler_exchange_service.h b/src/include/taler_exchange_service.h index 02ab182f2..b12edb05c 100644 --- a/src/include/taler_exchange_service.h +++ b/src/include/taler_exchange_service.h @@ -751,6 +751,7 @@ TALER_EXCHANGE_wire_cancel (struct TALER_EXCHANGE_WireHandle *wh); * @param deposit_fee the deposit fee we expect to pay * @param h_wire hash of the merchant’s account details * @param h_contract_terms hash of the contact of the merchant with the customer (further details are never disclosed to the exchange) + * @param h_denom_pub hash of the coin denomination's public key * @param coin_priv coin’s private key * @param wallet_timestamp timestamp when the contract was finalized, must not be too far in the future * @param merchant_pub the public key of the merchant (used to identify the merchant for refund requests) @@ -763,6 +764,7 @@ TALER_EXCHANGE_deposit_permission_sign ( const struct TALER_Amount *deposit_fee, const struct GNUNET_HashCode *h_wire, const struct GNUNET_HashCode *h_contract_terms, + const struct GNUNET_HashCode *h_denom_pub, const struct TALER_CoinSpendPrivateKeyP *coin_priv, struct GNUNET_TIME_Absolute wallet_timestamp, const struct TALER_MerchantPublicKeyP *merchant_pub, diff --git a/src/include/taler_exchangedb_plugin.h b/src/include/taler_exchangedb_plugin.h index d069bd2ec..a12aaa426 100644 --- a/src/include/taler_exchangedb_plugin.h +++ b/src/include/taler_exchangedb_plugin.h @@ -335,6 +335,11 @@ struct TALER_EXCHANGEDB_RecoupListEntry */ struct TALER_CoinSpendSignatureP coin_sig; + /** + * Hash of the public denomination key used to sign the coin. + */ + struct GNUNET_HashCode h_denom_pub; + /** * Public key of the reserve the coin was paid back into. */ @@ -608,6 +613,11 @@ struct TALER_EXCHANGEDB_DepositListEntry */ struct GNUNET_HashCode h_wire; + /** + * Hash of the public denomination key used to sign the coin. + */ + struct GNUNET_HashCode h_denom_pub; + /** * Detailed information about the receiver for executing the transaction. * Includes URL in payto://-format and salt. @@ -781,6 +791,11 @@ struct TALER_EXCHANGEDB_MeltListEntry */ struct TALER_RefreshCommitmentP rc; + /** + * Hash of the public denomination key used to sign the coin. + */ + struct GNUNET_HashCode h_denom_pub; + /** * How much value is being melted? This amount includes the fees, * so the final amount contributed to the melt is this value minus diff --git a/src/include/taler_signatures.h b/src/include/taler_signatures.h index 7f9e090a1..81e2e1c82 100644 --- a/src/include/taler_signatures.h +++ b/src/include/taler_signatures.h @@ -350,6 +350,11 @@ struct TALER_DepositRequestPS */ struct GNUNET_HashCode h_wire GNUNET_PACKED; + /** + * Hash over the denomination public key used to sign the coin. + */ + struct GNUNET_HashCode h_denom_pub GNUNET_PACKED; + /** * Time when this request was generated. Used, for example, to * assess when (roughly) the income was achieved for tax purposes. @@ -579,6 +584,12 @@ struct TALER_RefreshMeltCoinAffirmationPS */ struct TALER_RefreshCommitmentP rc GNUNET_PACKED; + /** + * Hash over the denomination public key used to sign the coin. + * FIXME: add here, initialize everywhere! + */ + // struct GNUNET_HashCode h_denom_pub GNUNET_PACKED; + /** * How much of the value of the coin should be melted? This amount * includes the fees, so the final amount contributed to the melt is -- cgit v1.2.3