Include invalid oidc token in the error message for debugging
This commit is contained in:
parent
ed897c7cb0
commit
1d246784dd
3 changed files with 9 additions and 5 deletions
|
@ -39,10 +39,10 @@ class OIDCInternalAuth(object):
|
|||
try:
|
||||
payload = self.login_service.decode_user_jwt(id_token)
|
||||
except InvalidTokenError as ite:
|
||||
logger.exception('Got invalid token error on OIDC decode: %s', ite.message)
|
||||
logger.exception('Got invalid token error on OIDC decode: %s. Token: %s', ite.message, id_token)
|
||||
return (None, 'Could not validate OIDC token')
|
||||
except PublicKeyLoadException as pke:
|
||||
logger.exception('Could not load public key during OIDC decode: %s', pke.message)
|
||||
logger.exception('Could not load public key during OIDC decode: %s. Token: %s', pke.message, id_token)
|
||||
return (None, 'Could not validate OIDC token')
|
||||
|
||||
# Find the user ID.
|
||||
|
|
Reference in a new issue