-
Notifications
You must be signed in to change notification settings - Fork 10
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
Add route keys/{kid}/jwk.json #48
Conversation
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.
Nicely done. Let's push this in our next release.
We should add content negotiation to the /keys/{kid]
endpoint to allow returning PEM or JWK, but that can be done in a follow-on PR.
I agree. This is great! 😄 Thanks, @Equanox! FYI: there are some failing tests in travis though. We should fix that before merging. |
Thx guys, will fix the failing tests. @johnabass didnt know exactly how to react properly to the Content-Type, is there a example in one of your repos? Then i will try to do a follow up PR. |
Codecov Report
@@ Coverage Diff @@
## master #48 +/- ##
==========================================
- Coverage 96.60% 95.48% -1.13%
==========================================
Files 38 39 +1
Lines 1209 1262 +53
==========================================
+ Hits 1168 1205 +37
- Misses 27 35 +8
- Partials 14 22 +8
Continue to review full report at Codecov.
|
We're in the process of retooling around content negotiation. We should just push this PR to master for now. We can redo an URLs or content negotation after we settle on a solution. |
https://github.com/xmidt-org/themis/releases/tag/v0.4.4 has this PR in it. I did change things a bit in #53. Notably, the specific URLs are |
JWK (https://tools.ietf.org/html/rfc7517) format seems to be a bit more common to expose the public key. This allows us to be more flexible in checking JWT validity.
I think it won't break anything as the pem route is still functional. The JWK creation is based on https://github.com/lestrrat-go/jwx .