From 7d6d2e4f277132dce4c751f6057764c72ac9db0a Mon Sep 17 00:00:00 2001 From: Frederick Muriuki Muriithi Date: Thu, 31 Aug 2023 08:04:59 +0300 Subject: Update with fixes done, and close the issue. --- issues/invalid-token-error.gmi | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) (limited to 'issues/invalid-token-error.gmi') diff --git a/issues/invalid-token-error.gmi b/issues/invalid-token-error.gmi index 8565726..d1a1f2e 100644 --- a/issues/invalid-token-error.gmi +++ b/issues/invalid-token-error.gmi @@ -5,7 +5,7 @@ * assigned: fredm, zsloan * type: bug * priority: high -* status: unresolved +* status: closed, completed, resolved * keywords: authentication ## Description @@ -20,10 +20,13 @@ After fully updating the code the error might be manifesting differently. I now UNAUTHORIZED: The access token provided is expired, revoked, malformed, or invalid for other reasons. ``` -This can be tested by adding the following after line 48 in gn3/auth/authentication/oauth2/server.py (which makes the token quickly expire): +This can be tested by adding the following configuration in the auth(entic|oris)ation server: ``` -"expires_in": (60) +OAUTH2_TOKEN_EXPIRES_IN = { + "authorization_code": 60 +} ``` +which sets up the tokens generated henceforth to expire in 60 seconds. * Full trace: ``` @@ -61,3 +64,9 @@ Traceback (most recent call last): raise InvalidTokenError() authlib.integrations.base_client.errors.InvalidTokenError: token_invalid: ``` + +## FIXES + +Should be fixed with the following commit(s) + +=> https://github.com/genenetwork/genenetwork2/commit/d818eaf1957c06405faf712a2be8526a7f63581b -- cgit v1.2.3