summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2022-02-06 18:39:28 +0100
committerChristian Grothoff <christian@grothoff.org>2022-02-06 18:39:28 +0100
commitf173296c3ca55bbd4a541d5a5859cdb1be125da7 (patch)
tree4d4fe5031f638394854743a8c2e402429df3dae0
parent57bbdb0997643a53615b8ebff11f22a4d6783d66 (diff)
downloadexchange-f173296c3ca55bbd4a541d5a5859cdb1be125da7.tar.gz
exchange-f173296c3ca55bbd4a541d5a5859cdb1be125da7.tar.bz2
exchange-f173296c3ca55bbd4a541d5a5859cdb1be125da7.zip
-fix refresh FTBFS
-rw-r--r--src/include/taler_crypto_lib.h9
-rw-r--r--src/lib/exchange_api_recoup.c17
-rw-r--r--src/lib/exchange_api_recoup_refresh.c1
3 files changed, 18 insertions, 9 deletions
diff --git a/src/include/taler_crypto_lib.h b/src/include/taler_crypto_lib.h
index 077d57859..bfa423ffd 100644
--- a/src/include/taler_crypto_lib.h
+++ b/src/include/taler_crypto_lib.h
@@ -1491,11 +1491,10 @@ TALER_planchet_setup_random (
* @param bks blinding secrets
*/
void
-TALER_planchet_blinding_secret_create (const struct TALER_PlanchetSecretsP *ps,
-
- const struct
- TALER_ExchangeWithdrawValues *alg_values,
- union TALER_DenominationBlindingKeyP *bks);
+TALER_planchet_blinding_secret_create (
+ const struct TALER_PlanchetSecretsP *ps,
+ const struct TALER_ExchangeWithdrawValues *alg_values,
+ union TALER_DenominationBlindingKeyP *bks);
/**
diff --git a/src/lib/exchange_api_recoup.c b/src/lib/exchange_api_recoup.c
index 4a7ac75e2..be26dc982 100644
--- a/src/lib/exchange_api_recoup.c
+++ b/src/lib/exchange_api_recoup.c
@@ -297,16 +297,25 @@ TALER_EXCHANGE_recoup (struct TALER_EXCHANGE_Handle *exchange,
json_t *recoup_obj;
CURL *eh;
char arg_str[sizeof (struct TALER_CoinSpendPublicKeyP) * 2 + 32];
+ struct TALER_CoinSpendPrivateKeyP coin_priv;
+ union TALER_DenominationBlindingKeyP bks;
GNUNET_assert (GNUNET_YES ==
TEAH_handle_is_ready (exchange));
- GNUNET_CRYPTO_eddsa_key_get_public (&ps->coin_priv.eddsa_priv,
+
+ TALER_planchet_setup_coin_priv (ps,
+ exchange_vals,
+ &coin_priv);
+ TALER_planchet_blinding_secret_create (ps,
+ exchange_vals,
+ &bks);
+ GNUNET_CRYPTO_eddsa_key_get_public (&coin_priv.eddsa_priv,
&coin_pub.eddsa_pub);
TALER_denom_pub_hash (&pk->key,
&h_denom_pub);
TALER_wallet_recoup_sign (&h_denom_pub,
- &ps->blinding_key,
- &ps->coin_priv,
+ &bks,
+ &coin_priv,
&coin_sig);
recoup_obj = GNUNET_JSON_PACK (
GNUNET_JSON_pack_data_auto ("denom_pub_hash",
@@ -316,7 +325,7 @@ TALER_EXCHANGE_recoup (struct TALER_EXCHANGE_Handle *exchange,
GNUNET_JSON_pack_data_auto ("coin_sig",
&coin_sig),
GNUNET_JSON_pack_data_auto ("coin_blind_key_secret",
- &ps->blinding_key));
+ &bks));
{
char pub_str[sizeof (struct TALER_CoinSpendPublicKeyP) * 2];
diff --git a/src/lib/exchange_api_recoup_refresh.c b/src/lib/exchange_api_recoup_refresh.c
index 03f756646..8c30e8eab 100644
--- a/src/lib/exchange_api_recoup_refresh.c
+++ b/src/lib/exchange_api_recoup_refresh.c
@@ -286,6 +286,7 @@ TALER_EXCHANGE_recoup_refresh (
struct TALER_EXCHANGE_Handle *exchange,
const struct TALER_EXCHANGE_DenomPublicKey *pk,
const struct TALER_DenominationSignature *denom_sig,
+ const struct TALER_ExchangeWithdrawValues *exchange_vals,
const struct TALER_PlanchetSecretsP *ps,
TALER_EXCHANGE_RecoupRefreshResultCallback recoup_cb,
void *recoup_cb_cls)