summaryrefslogtreecommitdiff
path: root/src/include
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2021-12-25 15:39:01 +0100
committerChristian Grothoff <christian@grothoff.org>2021-12-25 15:39:01 +0100
commitf6ecb6c895879ee4b5db3061593feaad3456d1c8 (patch)
tree81be844db2e275015592ca70994e90be013c9c87 /src/include
parent84c9adf5a6a243bd583f2144176f80708fa6a884 (diff)
downloadexchange-f6ecb6c895879ee4b5db3061593feaad3456d1c8.tar.gz
exchange-f6ecb6c895879ee4b5db3061593feaad3456d1c8.tar.bz2
exchange-f6ecb6c895879ee4b5db3061593feaad3456d1c8.zip
-eliminate redundant hash operation on link signatures
Diffstat (limited to 'src/include')
-rw-r--r--src/include/taler_crypto_lib.h6
-rw-r--r--src/include/taler_exchangedb_plugin.h16
2 files changed, 13 insertions, 9 deletions
diff --git a/src/include/taler_crypto_lib.h b/src/include/taler_crypto_lib.h
index db38c0c22..e6c5e2a4d 100644
--- a/src/include/taler_crypto_lib.h
+++ b/src/include/taler_crypto_lib.h
@@ -1788,8 +1788,7 @@ TALER_wallet_link_sign (const struct TALER_DenominationHash *h_denom_pub,
*
* @param h_denom_pub hash of the denomiantion public key of the new coin
* @param transfer_pub transfer public key
- * @param coin_ev coin envelope
- * @param coin_ev_size number of bytes in @a coin_ev
+ * @param h_coin_ev hash of the coin envelope
* @param old_coin_pub old coin key that the link signature is for
* @param coin_sig resulting signature
* @return #GNUNET_OK if the signature is valid
@@ -1798,8 +1797,7 @@ enum GNUNET_GenericReturnValue
TALER_wallet_link_verify (
const struct TALER_DenominationHash *h_denom_pub,
const struct TALER_TransferPublicKeyP *transfer_pub,
- const void *coin_ev,
- size_t coin_ev_size,
+ const struct TALER_BlindedCoinHash *h_coin_ev,
const struct TALER_CoinSpendPublicKeyP *old_coin_pub,
const struct TALER_CoinSpendSignatureP *coin_sig);
diff --git a/src/include/taler_exchangedb_plugin.h b/src/include/taler_exchangedb_plugin.h
index 357d9f073..3c7840ef0 100644
--- a/src/include/taler_exchangedb_plugin.h
+++ b/src/include/taler_exchangedb_plugin.h
@@ -1636,6 +1636,16 @@ struct TALER_EXCHANGEDB_RefreshRevealedCoin
struct TALER_CoinSpendSignatureP orig_coin_link_sig;
/**
+ * Hash of the blinded new coin, that is @e coin_ev.
+ */
+ struct TALER_BlindedCoinHash coin_envelope_hash;
+
+ /**
+ * Signature generated by the exchange over the coin (in blinded format).
+ */
+ struct TALER_BlindedDenominationSignature coin_sig;
+
+ /**
* Blinded message to be signed (in envelope), with @e coin_env_size bytes.
*/
char *coin_ev;
@@ -1645,10 +1655,6 @@ struct TALER_EXCHANGEDB_RefreshRevealedCoin
*/
size_t coin_ev_size;
- /**
- * Signature generated by the exchange over the coin (in blinded format).
- */
- struct TALER_BlindedDenominationSignature coin_sig;
};
@@ -2972,7 +2978,7 @@ struct TALER_EXCHANGEDB_Plugin
/**
- * Lookup in the database for the @a num_freshcoins coins that we
+ * Lookup in the database for the fresh coins that we
* created in the given refresh operation.
*
* @param cls the @e cls of this struct with the plugin-specific state