diff options
author | Christian Grothoff <christian@grothoff.org> | 2021-08-17 09:59:30 +0200 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2021-08-17 09:59:30 +0200 |
commit | 89b86abd79c15b0359689e687c0243693d35ecfd (patch) | |
tree | 64605d763513ce2eac277099262830b2f9e6ccb1 | |
parent | 18a56ec6791e21aa0fdc90f9ac13357ad12749de (diff) |
-resolve FIXME by moving comment to explain better
-rw-r--r-- | src/backend/taler-merchant-httpd_get-orders-ID.c | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/src/backend/taler-merchant-httpd_get-orders-ID.c b/src/backend/taler-merchant-httpd_get-orders-ID.c index bf60872c..957e32c9 100644 --- a/src/backend/taler-merchant-httpd_get-orders-ID.c +++ b/src/backend/taler-merchant-httpd_get-orders-ID.c @@ -873,6 +873,8 @@ TMH_get_orders_ID (const struct TMH_RequestHandler *rh, "lookup_contract_terms"); } + /* Note: when "!ord.requireClaimToken" and the client does not provide + a claim token (all zeros!), then token_match==TRUE below: */ token_match = (GNUNET_DB_STATUS_SUCCESS_ONE_RESULT == qs) && (0 == GNUNET_memcmp (&db_claim_token, &god->claim_token)); @@ -949,6 +951,8 @@ TMH_get_orders_ID (const struct TMH_RequestHandler *rh, TALER_EC_MERCHANT_GENERIC_ORDER_UNKNOWN, order_id); } + /* Note: when "!ord.requireClaimToken" and the client does not provide + a claim token (all zeros!), then token_match==TRUE below: */ token_match = (GNUNET_DB_STATUS_SUCCESS_ONE_RESULT == qs) && (0 == GNUNET_memcmp (&db_claim_token, &god->claim_token)); @@ -1003,14 +1007,6 @@ TMH_get_orders_ID (const struct TMH_RequestHandler *rh, { const char *public_reorder_url; - /* FIXME: taking this branch seems wrong for unclaimed - orders without claim token! Also seems to contradict - the spec, as there 'authOk' is defined to include the - || "! ord.requireClaimToken" part! - - FD: when "!ord.requireClaimToken" and the client does not provide - a claim token (already checked!), then token_match==TRUE. - */ GNUNET_log (GNUNET_ERROR_TYPE_INFO, "Neither claim token nor contract matched\n"); public_reorder_url = json_string_value (json_object_get ( |