[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[taler-merchant] branch master updated: return proper status codes when
From: |
gnunet |
Subject: |
[taler-merchant] branch master updated: return proper status codes when client sends bogus payment requests (#6817) |
Date: |
Sat, 24 Apr 2021 19:55:17 +0200 |
This is an automated email from the git hooks/post-receive script.
grothoff pushed a commit to branch master
in repository merchant.
The following commit(s) were added to refs/heads/master by this push:
new 77c92672 return proper status codes when client sends bogus payment
requests (#6817)
77c92672 is described below
commit 77c92672cd0f83964e8a6992295595653b0f31db
Author: Christian Grothoff <christian@grothoff.org>
AuthorDate: Sat Apr 24 19:55:14 2021 +0200
return proper status codes when client sends bogus payment requests (#6817)
---
src/backend/taler-merchant-httpd_post-orders-ID-pay.c | 15 ++++++---------
1 file changed, 6 insertions(+), 9 deletions(-)
diff --git a/src/backend/taler-merchant-httpd_post-orders-ID-pay.c
b/src/backend/taler-merchant-httpd_post-orders-ID-pay.c
index a8c6a3ef..31ccbbea 100644
--- a/src/backend/taler-merchant-httpd_post-orders-ID-pay.c
+++ b/src/backend/taler-merchant-httpd_post-orders-ID-pay.c
@@ -1,6 +1,6 @@
/*
This file is part of TALER
- (C) 2014-2020 Taler Systems SA
+ (C) 2014-2021 Taler Systems SA
TALER is free software; you can redistribute it and/or modify
it under the terms of the GNU Affero General Public License as
@@ -893,7 +893,8 @@ process_pay_with_exchange (void *cls,
pc->refund_deadline,
&dc->coin_sig,
&deposit_cb,
- dc);
+ dc,
+ &ec);
if (NULL == dc->dh)
{
/* Signature was invalid or some other constraint was not satisfied. If
@@ -902,15 +903,11 @@ process_pay_with_exchange (void *cls,
GNUNET_break_op (0);
resume_pay_with_response (
pc,
- MHD_HTTP_FORBIDDEN,
+ TALER_ErrorCode_get_http_status_safe (ec),
TALER_MHD_make_json_pack (
"{s:s, s:I, s:i}",
- "hint",
- TALER_ErrorCode_get_hint (
- TALER_EC_MERCHANT_POST_ORDERS_ID_PAY_COIN_SIGNATURE_INVALID),
- "code",
- (json_int_t)
- TALER_EC_MERCHANT_POST_ORDERS_ID_PAY_COIN_SIGNATURE_INVALID,
+ "hint", TALER_ErrorCode_get_hint (ec),
+ "code", (json_int_t) ec,
"coin_idx", i));
return;
}
--
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [taler-merchant] branch master updated: return proper status codes when client sends bogus payment requests (#6817),
gnunet <=