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

Verifying iat without leeway may break with poorly synced clocks #319

Closed
matthewrudy opened this issue May 28, 2019 · 1 comment
Closed

Comments

@matthewrudy
Copy link

matthewrudy commented May 28, 2019

I know this was raised on an earlier issue,
#247 (comment)

But I've only just tried to upgrade to 2.2.1,
and it breaks our tests because we did historically see iat verification errors due to clock sync issues between systems.

And using the iat_leeway was a solution for us.

I can see that the RFC was the motivation for this change
#247 (comment)

So the RFC says we MUST verify the nbf and exp claims
and each of these MAY have a leeway.

https://tools.ietf.org/html/rfc7519#section-4.1.4

However it says nothing about verifying the iat claim.
Just that it:

MUST be a number containing a NumericDate value

I believe the answer is to remove the verify_iat method,
and treat iat as just a point of information, not a field to verify.

As the RFC says:

The "iat" (issued at) claim identifies the time at which the JWT was issued.

https://tools.ietf.org/html/rfc7519#section-4.1.6

@matthewrudy matthewrudy changed the title Verifying iat without leeway breaks without synced clocks Verifying iat without leeway may break with poorly synced clocks May 28, 2019
@matthewrudy
Copy link
Author

ok,
I'm being silly,
will just turn it off.

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

1 participant