mirror of
https://github.com/dehydrated-io/dehydrated.git
synced 2026-01-11 22:30:44 +01:00
Incompliant JWK Thumbprints with leading zeroes #145
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @cpu on GitHub (Sep 14, 2016).
Hi there!
It seems that
dehydratedis generating JWA JWK thumbprints that don't match the specification. This came to my attention as part of this Let's Encrypt community forum thread.Section 2 of RFC 7518 defines
Base64urlUIntas:Further, Section 6.3 indicates that all of the RSA key parameters are expressed as
Base64urlUInt.It's not immediately obvious but the portion of the
Base64urlUIntdescription that mandates that the sequence use the minimum number of octets means that leading zero's should be removed. You can see how Go-Jose implements this as one example of a complaint implementation.It doesn't look to me that dehydrated strips leading zeroes presently to match the specification. I believe this might be the root cause of Issue #268 and is likely to cause further problems down the road for users that hit this corner case.
Unfortunately I don't work with bash or
dehydratedenough to propose a patch, but hopefully it won't be difficult to address! Let me know if I can provide any other information.@lukas2511 commented on GitHub (Sep 17, 2016):
@cpu hey, can you check if that commit fixed the problem?
@cpu commented on GitHub (Sep 17, 2016):
@lukas2511 I'm afraid I'm not a user of dehydrated and don't have a reproduction case. Apologies.
@lukas2511 commented on GitHub (Sep 21, 2016):
Commit was reverted in
a316a094dfbecause of problems with freebsd, reopening this ticket for now@lukas2511 commented on GitHub (Jan 30, 2017):
I wasn't ever able to reproduce any issues with this myself and it seems to be working fine... I'll close this issue until I have a reliable way of testing this. For the (seemingly very rare) case of people having this problem I'd suggest just trying to delete the key in question (or better: send it to me for testing! – of course only if there isn't anything validated with that yet) and let the script generate a new one.