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

Leeway #18

Closed
lukequinnell opened this issue Dec 10, 2020 · 1 comment
Closed

Leeway #18

lukequinnell opened this issue Dec 10, 2020 · 1 comment

Comments

@lukequinnell
Copy link

lukequinnell commented Dec 10, 2020

Firstly, thank you for your efforts here, its appreciated!

Does your library allow for use of the JWT::$leeway configuration?

"You can add a leeway to account for when there is a clock skew times between
the signing and verifying servers. It is recommended that this leeway should
not be bigger than a few minutes."
Source: http://self-issued.info/docs/draft-ietf-oauth-json-web-token.html#nbfDef

JWT::$leeway = 60; // $leeway in seconds
$decoded = JWT::decode($jwt, $key, array('HS256'))

@patrickbussmann
Copy link
Owner

I added it to the README.
Its supported because Firebase\JWT\JWT::$leeway is public static so it can be modified.

Thanks for information.

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