Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[8.x] Improve jwt logging on failed auth (#122247) #122782

Merged
merged 7 commits into from
Feb 21, 2025
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
Improve jwt logging on failed auth (#122247)
Update docs/changelog/122247.yaml
  • Loading branch information
jfreden committed Feb 17, 2025
commit e074ca87662f6ccddd532ec8aaa89ff7f9266bd3
5 changes: 5 additions & 0 deletions docs/changelog/122247.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
pr: 122247
summary: Improve jwt logging on failed auth
area: Authentication
type: bug
issues: []
Original file line number Diff line number Diff line change
Expand Up @@ -263,12 +263,10 @@ public void authenticate(final AuthenticationToken authenticationToken, final Ac
+ tokenPrincipal
+ "] with header ["
+ jwtAuthenticationToken.getSignedJWT().getHeader()
+ "] and claimSet ["
+ jwtAuthenticationToken.getJWTClaimsSet()
+ "]";

if (logger.isTraceEnabled()) {
logger.trace(msg, ex);
logger.trace(msg + " and claimSet [" + jwtAuthenticationToken.getJWTClaimsSet() + "]", ex);
} else {
logger.debug(msg + " Cause: " + ex.getMessage()); // only log the stack trace at trace level
}
Expand Down