summaryrefslogtreecommitdiff
path: root/src/testing/testing_api_cmd_deposit.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2023-09-24 19:03:30 +0200
committerChristian Grothoff <christian@grothoff.org>2023-09-24 19:03:30 +0200
commitc6f7bd46fe73236dd3464cc6d87a5bce92c1ef16 (patch)
tree9eb74c5348ffefac412c3adcbc0e2e1d81c5d217 /src/testing/testing_api_cmd_deposit.c
parentcb60a5695d330de0feea2fb4800ca853a8ffe0ed (diff)
downloadexchange-c6f7bd46fe73236dd3464cc6d87a5bce92c1ef16.tar.gz
exchange-c6f7bd46fe73236dd3464cc6d87a5bce92c1ef16.tar.bz2
exchange-c6f7bd46fe73236dd3464cc6d87a5bce92c1ef16.zip
combine deposit confirmation signatures into one big signature
Diffstat (limited to 'src/testing/testing_api_cmd_deposit.c')
-rw-r--r--src/testing/testing_api_cmd_deposit.c15
1 files changed, 10 insertions, 5 deletions
diff --git a/src/testing/testing_api_cmd_deposit.c b/src/testing/testing_api_cmd_deposit.c
index 0ee6aa447..61074afa7 100644
--- a/src/testing/testing_api_cmd_deposit.c
+++ b/src/testing/testing_api_cmd_deposit.c
@@ -69,6 +69,11 @@ struct DepositState
unsigned int coin_index;
/**
+ * Our coin signature.
+ */
+ struct TALER_CoinSpendSignatureP coin_sig;
+
+ /**
* Wire details of who is depositing -- this would be merchant
* wire details in a normal scenario.
*/
@@ -258,11 +263,10 @@ deposit_cb (void *cls,
}
if (MHD_HTTP_OK == dr->hr.http_status)
{
- GNUNET_assert (1 == dr->details.ok.num_signatures);
ds->deposit_succeeded = GNUNET_YES;
ds->exchange_timestamp = dr->details.ok.deposit_timestamp;
ds->exchange_pub = *dr->details.ok.exchange_pub;
- ds->exchange_sig = dr->details.ok.exchange_sigs[0];
+ ds->exchange_sig = *dr->details.ok.exchange_sig;
}
TALER_TESTING_interpreter_next (ds->is);
}
@@ -287,7 +291,6 @@ deposit_run (void *cls,
const struct TALER_AgeCommitmentHash *phac;
const struct TALER_EXCHANGE_DenomPublicKey *denom_pub;
const struct TALER_DenominationSignature *denom_pub_sig;
- struct TALER_CoinSpendSignatureP coin_sig;
struct TALER_MerchantPublicKeyP merchant_pub;
struct TALER_PrivateContractHashP h_contract_terms;
enum TALER_ErrorCode ec;
@@ -449,14 +452,14 @@ deposit_run (void *cls,
&merchant_pub,
ds->refund_deadline,
coin_priv,
- &coin_sig);
+ &ds->coin_sig);
}
GNUNET_assert (NULL == ds->dh);
{
struct TALER_EXCHANGE_CoinDepositDetail cdd = {
.amount = ds->amount,
.coin_pub = coin_pub,
- .coin_sig = coin_sig,
+ .coin_sig = ds->coin_sig,
.denom_sig = *denom_pub_sig,
.h_denom_pub = denom_pub->h_key,
.h_age_commitment = {{{0}}},
@@ -595,6 +598,8 @@ deposit_traits (void *cls,
/* These traits are always available */
TALER_TESTING_make_trait_coin_priv (0,
coin_spent_priv),
+ TALER_TESTING_make_trait_coin_sig (0,
+ &ds->coin_sig),
TALER_TESTING_make_trait_age_commitment_proof (0,
age_commitment_proof),
TALER_TESTING_make_trait_h_age_commitment (0,