Skip to content
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

Allow IssuedAtClaim to compare dates #42

Closed
hhanesand opened this issue Apr 5, 2017 · 2 comments
Closed

Allow IssuedAtClaim to compare dates #42

hhanesand opened this issue Apr 5, 2017 · 2 comments

Comments

@hhanesand
Copy link

I'm using Firebase to manage my users, and I use this library to validate JWT tokens sent by Firebase. In their documentation, they state that I must validate that the Issued-at time is in the past. I don't think I can do this with the current implementation, as IssuedAtClaim forces comparison to a specific time.

@siemensikkema
Copy link
Member

I had a look at the jwt spec and in section 4.1.6. it does not say anything about how to verify these claims. I now see the implementation I chose does not fit all needs :(
The good news is that you don't have to use the provided claims. What you need is the opposite of NotBeforeClaim so you could copy and adjust the verify function and the static name variable.

@hhanesand
Copy link
Author

Ah, ok. Thanks for the response.

Also, thank you for the work you did here! This allowed me to remove a janky Swift + Ruby system I had set in place :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants