-
Notifications
You must be signed in to change notification settings - Fork 1.5k
fix: use up-to-date kid
in JWT header when refreshing
#3973
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
base: master
Are you sure you want to change the base?
Conversation
576225f
to
ed11711
Compare
Not sure if there's anything I should do about the CodeQL scanning results task failing. It seems spurious. |
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.
Thank you and good approach, some ideas to improve it further. I accepted the CodeQL issues
"extra": { | ||
} | ||
}, | ||
"headers": null, |
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.
Please keep the headers.extra keys, as changing them to null will potentially break webhook receivers.
rotateJwks("hydra.jwt.access-token") | ||
rotateJwks("hydra.openid.id-token") | ||
|
||
cy.refreshTokenBrowser(client, tokensBefore.refresh_token).then( |
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.
This test isn't actually checking that the kid
is set correctly, it only validates its non-equality. Can you please make sure that the kid is set correctly - either with a regex (expect a non-nil uuid) or some other way?
From the snapshots it looks like it was public:hydra.jwt.access-token
before. What is the value now?
I pushed up three commits to restore the |
Also, please let me know how you'd like me to resolve conflicts, if at all. I can merge or rebase or squash at your preference. |
Co-authored-by: Randall Leeds <[email protected]>
I realized the checks wouldn't even run due to the conflict, so I rebased and squashed. |
And, I think the CI jobs flaked, but I can't re-run them. 😞 |
This PR is a variation on #3942 that attempts to solve the problem by letting fosite set the
kid
header of tokens and removing all of the code to explicitly set this header in JWTs.