diff options
author | Christian Grothoff <grothoff@gnunet.org> | 2022-07-01 07:22:39 +0200 |
---|---|---|
committer | Christian Grothoff <grothoff@gnunet.org> | 2022-07-01 07:22:39 +0200 |
commit | 9e3fb2302d72a285067ccc39038481afcab97dc2 (patch) | |
tree | 709d884502b5c8499772b93b2c8eeade160885f3 /src/exchange | |
parent | 085e40bc562343221bceb6fc4dc9aba8e32a27e3 (diff) | |
parent | 21551bb4c3c887fdcfb3d814c8ab4d1a4ec82945 (diff) | |
download | exchange-9e3fb2302d72a285067ccc39038481afcab97dc2.tar.gz exchange-9e3fb2302d72a285067ccc39038481afcab97dc2.tar.bz2 exchange-9e3fb2302d72a285067ccc39038481afcab97dc2.zip |
-gana merge
Diffstat (limited to 'src/exchange')
-rw-r--r-- | src/exchange/taler-exchange-httpd_common_deposit.c | 8 | ||||
-rw-r--r-- | src/exchange/taler-exchange-httpd_db.c | 6 | ||||
-rw-r--r-- | src/exchange/taler-exchange-httpd_wire.c | 1 |
3 files changed, 8 insertions, 7 deletions
diff --git a/src/exchange/taler-exchange-httpd_common_deposit.c b/src/exchange/taler-exchange-httpd_common_deposit.c index 694dfa411..92e2469f2 100644 --- a/src/exchange/taler-exchange-httpd_common_deposit.c +++ b/src/exchange/taler-exchange-httpd_common_deposit.c @@ -224,13 +224,13 @@ TEH_common_deposit_check_purse_deposit ( GNUNET_break_op (0); return TALER_MHD_reply_with_error (connection, MHD_HTTP_BAD_REQUEST, - /* FIXME: other error code? */ - TALER_EC_EXCHANGE_GENERIC_COIN_CONFLICTING_AGE_HASH, + TALER_EC_EXCHANGE_PURSE_DEPOSIT_COIN_CONFLICTING_ATTEST_VS_AGE_COMMITMENT, "mismatch of attest and age_commitment"); } if (coin->cpi.no_age_commitment) return GNUNET_OK; /* unrestricted coin */ + /* age attestation must be valid */ if (GNUNET_OK != TALER_age_commitment_verify (&coin->age_commitment, @@ -241,7 +241,7 @@ TEH_common_deposit_check_purse_deposit ( return TALER_MHD_reply_with_error (connection, MHD_HTTP_BAD_REQUEST, /* FIXME: other error code? */ - TALER_EC_EXCHANGE_GENERIC_COIN_CONFLICTING_AGE_HASH, + TALER_EC_EXCHANGE_PURSE_DEPOSIT_COIN_AGE_ATTESTATION_FAILURE, "invalid attest for minimum age"); } return GNUNET_OK; @@ -259,7 +259,7 @@ TEH_common_purse_deposit_free_coin (struct TEH_PurseDepositedCoin *coin) { TALER_denom_sig_free (&coin->cpi.denom_sig); if (! coin->cpi.no_age_commitment) - TALER_age_commitment_free (&coin->age_commitment); + GNUNET_free (coin->age_commitment.keys); /* Only the keys have been allocated */ } diff --git a/src/exchange/taler-exchange-httpd_db.c b/src/exchange/taler-exchange-httpd_db.c index f0c551398..6f0fc41c9 100644 --- a/src/exchange/taler-exchange-httpd_db.c +++ b/src/exchange/taler-exchange-httpd_db.c @@ -61,7 +61,8 @@ TEH_make_coin_known (const struct TALER_CoinPublicInfo *coin, NULL); return GNUNET_DB_STATUS_HARD_ERROR; case TALER_EXCHANGEDB_CKS_DENOM_CONFLICT: - /* FIXME-Oec: insufficient_funds != denom conflict! */ + /* FIXME: insufficient_funds != denom conflict! See issue 0007267, need new + * strategy for evidence gathering */ *mhd_ret = TEH_RESPONSE_reply_coin_insufficient_funds ( connection, TALER_EC_EXCHANGE_GENERIC_COIN_CONFLICTING_DENOMINATION_KEY, @@ -69,7 +70,8 @@ TEH_make_coin_known (const struct TALER_CoinPublicInfo *coin, &coin->coin_pub); return GNUNET_DB_STATUS_HARD_ERROR; case TALER_EXCHANGEDB_CKS_AGE_CONFLICT: - /* FIXME-Oec: insufficient_funds != Age conflict! */ + /* FIXME: insufficient_funds != Age conflict! See issue 0007267, need new + * strategy for evidence gathering */ *mhd_ret = TEH_RESPONSE_reply_coin_insufficient_funds ( connection, TALER_EC_EXCHANGE_GENERIC_COIN_CONFLICTING_AGE_HASH, diff --git a/src/exchange/taler-exchange-httpd_wire.c b/src/exchange/taler-exchange-httpd_wire.c index ce8293c9a..7e5f0a915 100644 --- a/src/exchange/taler-exchange-httpd_wire.c +++ b/src/exchange/taler-exchange-httpd_wire.c @@ -482,7 +482,6 @@ build_wire_state (void) MHD_HTTP_HEADER_EXPIRES, wsh->dat)); } - TALER_MHD_add_global_headers (wsh->wire_reply); /* Set cache control headers: our response varies depending on these headers */ GNUNET_break (MHD_YES == MHD_add_response_header (wsh->wire_reply, |