-
Notifications
You must be signed in to change notification settings - Fork 4.9k
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] [JWT Integration] Fix for error handling in ParseWithClaims can lead to potentially dangerous situations #42241
base: main
Are you sure you want to change the base?
Conversation
💚 CLA has been signed |
This pull request doesn't have a |
This pull request does not have a backport label.
To fixup this pull request, you need to add the backport labels for the needed
|
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixes vulnerability identified as CVE-2024-51744
. This update addresses the issue with great improvements and ensures better security.
/cla |
Proposed commit message
Unclear documentation of the error behavior in ParseWithClaims can lead to situation where users are potentially not checking errors in the way they should be. Especially, if a token is both expired and invalid, the errors returned by ParseWithClaims return both error codes. If users only check for the jwt.ErrTokenExpired using error.Is, they will ignore the embedded jwt.ErrTokenSignatureInvalid and thus potentially accept invalid tokens.
WeaknessCWE-347
WeaknessCWE-755
\
Checklist
CHANGELOG.next.asciidoc
orCHANGELOG-developer.next.asciidoc
.