summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSchanzenbach, Martin <mschanzenbach@posteo.de>2020-05-05 10:27:56 +0200
committerSchanzenbach, Martin <mschanzenbach@posteo.de>2020-05-05 10:27:56 +0200
commit067059ee3b632dcc0fe872de72c1964bca941742 (patch)
treec0feb23250fb389f0563044b27784b9f4625183d
parent80b88d6a6871ed8dcb24bcc8babdde3a17aad679 (diff)
fix attestations
-rw-r--r--src/reclaim/oidc_helper.c1
-rw-r--r--src/reclaim/plugin_rest_openid_connect.c8
2 files changed, 7 insertions, 2 deletions
diff --git a/src/reclaim/oidc_helper.c b/src/reclaim/oidc_helper.c
index 29e8cb2ef..5d04ef6b2 100644
--- a/src/reclaim/oidc_helper.c
+++ b/src/reclaim/oidc_helper.c
@@ -710,6 +710,7 @@ OIDC_parse_authz_code (const struct GNUNET_CRYPTO_EcdsaPrivateKey *ecdsa_priv,
attrs_ser = ((char *) &params[1]) + code_challenge_len;
attrs_ser_len = ntohl (params->attr_list_len);
*attrs = GNUNET_RECLAIM_attribute_list_deserialize (attrs_ser, attrs_ser_len);
+ *attests = GNUNET_new (struct GNUNET_RECLAIM_AttestationList);
*nonce_str = NULL;
if (nonce != 0)
diff --git a/src/reclaim/plugin_rest_openid_connect.c b/src/reclaim/plugin_rest_openid_connect.c
index 295de0d97..c6fa40687 100644
--- a/src/reclaim/plugin_rest_openid_connect.c
+++ b/src/reclaim/plugin_rest_openid_connect.c
@@ -549,6 +549,8 @@ cleanup_handle (struct RequestHandle *handle)
GNUNET_RECLAIM_get_attestations_stop (handle->attest_it);
if (NULL != handle->ticket_it)
GNUNET_RECLAIM_ticket_iteration_stop (handle->ticket_it);
+ if (NULL != handle->idp_op)
+ GNUNET_RECLAIM_cancel (handle->idp_op);
if (NULL != handle->idp)
GNUNET_RECLAIM_disconnect (handle->idp);
GNUNET_free_non_null (handle->url);
@@ -1784,8 +1786,8 @@ token_endpoint (struct GNUNET_REST_RequestHandle *con_handle,
struct RequestHandle *handle = cls;
const struct EgoEntry *ego_entry;
struct GNUNET_TIME_Relative expiration_time;
- struct GNUNET_RECLAIM_AttributeList *cl;
- struct GNUNET_RECLAIM_AttestationList *al;
+ struct GNUNET_RECLAIM_AttributeList *cl = NULL;
+ struct GNUNET_RECLAIM_AttestationList *al = NULL;
struct GNUNET_RECLAIM_Ticket ticket;
struct GNUNET_CRYPTO_EcdsaPublicKey cid;
const struct GNUNET_CRYPTO_EcdsaPrivateKey *privkey;
@@ -1948,6 +1950,8 @@ consume_ticket (void *cls,
const struct GNUNET_RECLAIM_Attestation *attest)
{
struct RequestHandle *handle = cls;
+ handle->idp_op = NULL;
+
if (NULL == identity)
{
GNUNET_SCHEDULER_add_now (&return_userinfo_response, handle);