From 387419ff9c6b66624c3e93b05ee584e9f5245959 Mon Sep 17 00:00:00 2001 From: Hans Zandbelt Date: Thu, 31 Aug 2023 06:54:48 +0100 Subject: [PATCH] printout more cjose error details in JWT access token verification Signed-off-by: Hans Zandbelt --- ChangeLog | 3 +++ src/jose.c | 5 ++--- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/ChangeLog b/ChangeLog index 5b163a6..cd0dd43 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,6 @@ +08/31/2023 +- printout more cjose error details when errors occur verifying JWT access tokens + 06/29/2023 - fix timing issue in check_openidc.c; closes #47 - bump to 1.5.2dev diff --git a/src/jose.c b/src/jose.c index b8fb8e2..d36ad3b 100644 --- a/src/jose.c +++ b/src/jose.c @@ -1278,7 +1278,7 @@ bool oauth2_jose_jwt_verify(oauth2_log_t *log, jws = cjose_jws_import(token, strlen(token), &err); if (jws == NULL) { - oauth2_error(log, "cjose_jws_import failed: %s", err.message); + _OAUTH2_UTIL_JOSE_ERR_LOG(log, "cjose_jws_import", err); goto end; } @@ -1317,8 +1317,7 @@ bool oauth2_jose_jwt_verify(oauth2_log_t *log, if (cjose_jws_get_plaintext(jws, &plaintext, &plaintext_len, &err) == false) { - oauth2_error(log, "cjose_jws_get_plaintext failed: %s", - err.message); + _OAUTH2_UTIL_JOSE_ERR_LOG(log, "cjose_jws_get_plaintext", err); goto end; }