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

Fix expires_in in OAuth2 Token is too huge #39

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

YoitoFes
Copy link

@YoitoFes YoitoFes commented Aug 11, 2022

According to RFC6749, expires_in in OAuth2 Token is the lifetime in seconds of the access token.

But mockoidc set MockOIDC.AccessTTL directly to expires_in, making expires_in huge; e.g. if AccessTTL = 10 * time.Seconds (1000000000), expires_in becomes 10000000000 in seconds.

Fix it.

Close #38

Signed-off-by: Naoto Kobayashi [email protected]

According to RFC6749, expires_in in OAuth2 Token is the lifetime in
seconds of the access token.

- https://www.rfc-editor.org/rfc/rfc6749#section-4.2.2

But mockoidc set MockOIDC.AccessTTL directly to expires_in, making
expires_in huge; e.g. if AccessTTL = 10 * time.Seconds (1000000000),
expires_in becomes 10000000000 in seconds.

Fix it.

Signed-off-by: Naoto Kobayashi <[email protected]>
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

Successfully merging this pull request may close these issues.

expires_in in OAuth2 Token is too huge
1 participant