From b280b1db0456e883c9976579ea929ed47cbbb7f5 Mon Sep 17 00:00:00 2001 From: Gian Demarmels Date: Sat, 5 Feb 2022 23:12:21 +0100 Subject: fix src/util --- src/util/test_helper_cs.c | 65 ++++++++++++++++++++++++++++++++++------------- 1 file changed, 48 insertions(+), 17 deletions(-) (limited to 'src/util/test_helper_cs.c') diff --git a/src/util/test_helper_cs.c b/src/util/test_helper_cs.c index c4e68376..4f635d40 100644 --- a/src/util/test_helper_cs.c +++ b/src/util/test_helper_cs.c @@ -267,12 +267,19 @@ test_r_derive (struct TALER_CRYPTO_CsDenominationHelper *dh) enum TALER_ErrorCode ec; bool success = false; struct TALER_PlanchetSecretsP ps; + struct TALER_CoinSpendPrivateKeyP coin_priv; + union TALER_DenominationBlindingKeyP bks; struct TALER_CoinPubHash c_hash; struct TALER_ExchangeWithdrawValues alg_values; + GNUNET_CRYPTO_random_block (GNUNET_CRYPTO_QUALITY_STRONG, + &ps, + sizeof (ps)); + alg_values.cipher = TALER_DENOMINATION_CS; - TALER_planchet_setup_random (&ps, - &alg_values); + TALER_planchet_setup_coin_priv (&ps, &alg_values, &coin_priv); + TALER_planchet_blinding_secret_create (&ps, &alg_values, &bks); + for (unsigned int i = 0; i