diff options
author | Christian Grothoff <christian@grothoff.org> | 2022-11-06 22:29:51 +0100 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2022-11-06 22:29:51 +0100 |
commit | f8e9241a3d4adb3e31e8691782136aaed88b41da (patch) | |
tree | 0c7e34c8b6db55e42294e843e3f9363d4d754b98 /src/exchange | |
parent | 6d59c19f363d0eb7a0ba94646914624df56bd14a (diff) | |
download | exchange-f8e9241a3d4adb3e31e8691782136aaed88b41da.tar.gz exchange-f8e9241a3d4adb3e31e8691782136aaed88b41da.tar.bz2 exchange-f8e9241a3d4adb3e31e8691782136aaed88b41da.zip |
fix #7427
Diffstat (limited to 'src/exchange')
-rw-r--r-- | src/exchange/taler-exchange-httpd_kyc-check.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/src/exchange/taler-exchange-httpd_kyc-check.c b/src/exchange/taler-exchange-httpd_kyc-check.c index 55199593e..47338ae96 100644 --- a/src/exchange/taler-exchange-httpd_kyc-check.c +++ b/src/exchange/taler-exchange-httpd_kyc-check.c @@ -93,6 +93,11 @@ struct KycPoller struct GNUNET_TIME_Absolute timeout; /** + * If the KYC complete, what kind of data was collected? + */ + json_t *kyc_details; + + /** * Set to starting URL of KYC process if KYC is required. */ char *kyc_url; @@ -195,6 +200,7 @@ kyp_cleanup (struct TEH_RequestContext *rc) kyp->ih_logic->initiate_cancel (kyp->ih); kyp->ih = NULL; } + json_decref (kyp->kyc_details); GNUNET_free (kyp->kyc_url); GNUNET_free (kyp->hint); GNUNET_free (kyp); @@ -327,9 +333,16 @@ kyc_check (void *cls, if (TALER_KYCLOGIC_check_satisfied ( requirements, &h_payto, + &kyp->kyc_details, TEH_plugin->select_satisfied_kyc_processes, TEH_plugin->cls)) + { + GNUNET_log (GNUNET_ERROR_TYPE_INFO, + "KYC requirements `%s' already satisfied\n", + requirements); + GNUNET_free (requirements); return GNUNET_DB_STATUS_SUCCESS_NO_RESULTS; + } kyp->kyc_required = true; ret = TALER_KYCLOGIC_requirements_to_logic (requirements, @@ -610,6 +623,7 @@ TEH_handler_kyc_check ( (ec = TALER_exchange_online_account_setup_success_sign ( &TEH_keys_exchange_sign_, &kyp->h_payto, + kyp->kyc_details, now, &pub, &sig))) @@ -625,6 +639,8 @@ TEH_handler_kyc_check ( &sig), GNUNET_JSON_pack_data_auto ("exchange_pub", &pub), + GNUNET_JSON_pack_object_incref ("kyc_details", + kyp->kyc_details), GNUNET_JSON_pack_timestamp ("now", now)); } |