Enable an option to config the leeway for claim validation #228
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Issues
Fixes: #229
Background
At the moment, the existing valid method allows a passed in configuration to set some leeways.
For example:
authlib/authlib/oidc/core/claims.py
Line 26 in 36e2236
However, this has been hardcoded to
2 minutes
in the invocation.For example:
authlib/authlib/integrations/base_client/remote_app.py
Line 200 in 36e2236
Changes
This will enable an option for developers to configure the leeway as designated.
So that when we call the
parse_id_token
, in addition to the existing optionwe can also set up
What kind of change does this PR introduce? (check at least one)
Does this PR introduce a breaking change? (check one)