aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSchanzenbach, Martin <mschanzenbach@posteo.de>2019-04-27 11:12:38 +0200
committerSchanzenbach, Martin <mschanzenbach@posteo.de>2019-04-27 11:12:38 +0200
commitb012c3f7b0156bf682894f4486ef628f8acf4078 (patch)
tree1c51f537e380d673eb5e4dde8d06674694c02512
parentf0688c57bf1f85bbb71d166b33317db0bd565008 (diff)
downloadgnunet-b012c3f7b0156bf682894f4486ef628f8acf4078.tar.gz
gnunet-b012c3f7b0156bf682894f4486ef628f8acf4078.zip
RECLAIM/OIDC: nonce logging
-rw-r--r--src/reclaim/oidc_helper.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/reclaim/oidc_helper.c b/src/reclaim/oidc_helper.c
index fb0fb2e08..abe7fa623 100644
--- a/src/reclaim/oidc_helper.c
+++ b/src/reclaim/oidc_helper.c
@@ -360,6 +360,8 @@ OIDC_build_authz_code (const struct GNUNET_CRYPTO_EcdsaPrivateKey *issuer,
360 GNUNET_free_non_null (attrs_ser); 360 GNUNET_free_non_null (attrs_ser);
361 return NULL; 361 return NULL;
362 } 362 }
363 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
364 "Got nonce: %u from %s\n", nonce, nonce_str);
363 } 365 }
364 nonce_tmp = htonl (nonce); 366 nonce_tmp = htonl (nonce);
365 memcpy (buf_ptr, &nonce_tmp, sizeof (uint32_t)); 367 memcpy (buf_ptr, &nonce_tmp, sizeof (uint32_t));
@@ -415,7 +417,7 @@ OIDC_parse_authz_code (const struct GNUNET_CRYPTO_EcdsaPublicKey *audience,
415 size_t code_payload_len; 417 size_t code_payload_len;
416 size_t attrs_ser_len; 418 size_t attrs_ser_len;
417 size_t signature_offset; 419 size_t signature_offset;
418 uint32_t nonce; 420 uint32_t nonce = 0;
419 421
420 GNUNET_log (GNUNET_ERROR_TYPE_ERROR, "Trying to decode `%s'", code); 422 GNUNET_log (GNUNET_ERROR_TYPE_ERROR, "Trying to decode `%s'", code);
421 code_payload = NULL; 423 code_payload = NULL;
@@ -440,6 +442,8 @@ OIDC_parse_authz_code (const struct GNUNET_CRYPTO_EcdsaPublicKey *audience,
440 attrs_ser_len -= sizeof (struct GNUNET_RECLAIM_Ticket); 442 attrs_ser_len -= sizeof (struct GNUNET_RECLAIM_Ticket);
441 ptr += sizeof (struct GNUNET_RECLAIM_Ticket); 443 ptr += sizeof (struct GNUNET_RECLAIM_Ticket);
442 nonce = ntohl (*((uint32_t *) ptr)); 444 nonce = ntohl (*((uint32_t *) ptr));
445 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
446 "Got nonce: %u\n", nonce);
443 attrs_ser_len -= sizeof (uint32_t); 447 attrs_ser_len -= sizeof (uint32_t);
444 ptr += sizeof (uint32_t); 448 ptr += sizeof (uint32_t);
445 attrs_ser_len -= sizeof (struct GNUNET_CRYPTO_EcdsaSignature); 449 attrs_ser_len -= sizeof (struct GNUNET_CRYPTO_EcdsaSignature);