jwt
jwt copied to clipboard
Expiration skew
Hello! is there a way to add an expiration skew to the jwt.Parse() function to add for example 5 minute buffer for expiry?
let's say the token expired at 12:50:30 and now it is 12:53:05 since we are still within a 5-minute window, the JWT should be accepted as valid.
This is sort of a duplicate of #16 and #98. We are currently working on a v5 of this module and one of the first improvements is a new API for the validation of tokens.
You can find the PR here: https://github.com/golang-jwt/jwt/pull/236. Feel free to check it out, but be aware that the API is not stable yet.
Thanks for the quick reply. I guess I'll have to wait till it's stable. Thanks for your amazing work.
Fixed by #234