diff options
author | Özgür Kesim <oec-taler@kesim.org> | 2023-07-26 17:36:13 +0200 |
---|---|---|
committer | Özgür Kesim <oec-taler@kesim.org> | 2023-07-26 17:36:13 +0200 |
commit | d20804124025c259af1bc3e00ceed653c734b468 (patch) | |
tree | 5641b89f8367b15fa112d897dc26f55bdc448a21 /src/lib/exchange_api_age_withdraw_reveal.c | |
parent | 0f17931b108deacb75eafa36234de088d38be22e (diff) | |
download | exchange-d20804124025c259af1bc3e00ceed653c734b468.tar.gz exchange-d20804124025c259af1bc3e00ceed653c734b468.tar.bz2 exchange-d20804124025c259af1bc3e00ceed653c734b468.zip |
[age-withdraw] reveal works, tested.
Tests for age-withdraw and the reveal now work for both, RSA and CS.
Diffstat (limited to 'src/lib/exchange_api_age_withdraw_reveal.c')
-rw-r--r-- | src/lib/exchange_api_age_withdraw_reveal.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/lib/exchange_api_age_withdraw_reveal.c b/src/lib/exchange_api_age_withdraw_reveal.c index 1e804bc84..a448d109d 100644 --- a/src/lib/exchange_api_age_withdraw_reveal.c +++ b/src/lib/exchange_api_age_withdraw_reveal.c @@ -118,17 +118,18 @@ age_withdraw_reveal_ok ( { struct TALER_BlindedDenominationSignature denom_sigs[awrh->num_coins]; + json_t *j_sig; + size_t n; /* Reconstruct the coins and unblind the signatures */ - for (size_t n = 0; n < awrh->num_coins; n++) + json_array_foreach (j_sigs, n, j_sig) { - json_t *j_sig = json_array_get (j_sigs, n); struct GNUNET_JSON_Specification spec[] = { - GNUNET_JSON_spec_fixed_auto ("", &denom_sigs[n]), + TALER_JSON_spec_blinded_denom_sig (NULL, + &denom_sigs[n]), GNUNET_JSON_spec_end () }; - GNUNET_assert (NULL != j_sig); if (GNUNET_OK != GNUNET_JSON_parse (j_sig, spec, NULL, NULL)) @@ -136,6 +137,7 @@ age_withdraw_reveal_ok ( GNUNET_break_op (0); return GNUNET_SYSERR; } + } response.details.ok.num_sigs = awrh->num_coins; |