Skip to content
This repository was archived by the owner on Mar 6, 2026. It is now read-only.

fix: rename CLOCK_SKEW and separate client/server user case#863

Merged
arithmetic1728 merged 2 commits intomainfrom
clock
Sep 10, 2021
Merged

fix: rename CLOCK_SKEW and separate client/server user case#863
arithmetic1728 merged 2 commits intomainfrom
clock

Conversation

@arithmetic1728
Copy link
Copy Markdown
Contributor

  1. Rename _helper.CLOCK_SKEW to _helper.REFRESH_THRESHOLD. This value is for client to decide when to refresh a token.
  2. Add a clock_skew_in_seconds keyword parameter (default value is 0) to jwt.decode, and remove the hard coded _helper.CLOCK_SKEW in the logic. The reason is jwt.decode is for server usage to validate iat/exp value. We should leave the clock skew to the server since this is server specific.

@arithmetic1728 arithmetic1728 requested a review from a team September 8, 2021 06:35
@google-cla google-cla Bot added the cla: yes This human has signed the Contributor License Agreement. label Sep 8, 2021
Comment thread google/auth/_helpers.py Outdated
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

cla: yes This human has signed the Contributor License Agreement.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants