From 1866cfdbae469cb72fb5eeb7df3239e81fb7eb27 Mon Sep 17 00:00:00 2001 From: Georges-Antoine Assi Date: Wed, 27 Nov 2024 23:39:53 -0500 Subject: [PATCH] revert one oauth to oidc change --- backend/handler/auth/base_handler.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/backend/handler/auth/base_handler.py b/backend/handler/auth/base_handler.py index b4d5d93af..ffb72e4c5 100644 --- a/backend/handler/auth/base_handler.py +++ b/backend/handler/auth/base_handler.py @@ -13,7 +13,7 @@ from passlib.context import CryptContext from starlette.requests import HTTPConnection ALGORITHM: Final = "HS256" -DEFAULT_OIDC_TOKEN_EXPIRY: Final = timedelta(minutes=15) +DEFAULT_OAUTH_TOKEN_EXPIRY: Final = timedelta(minutes=15) class Scope(enum.StrEnum): @@ -126,7 +126,7 @@ class OAuthHandler: pass def create_oauth_token( - self, data: dict, expires_delta: timedelta = DEFAULT_OIDC_TOKEN_EXPIRY + self, data: dict, expires_delta: timedelta = DEFAULT_OAUTH_TOKEN_EXPIRY ) -> str: to_encode = data.copy() expire = datetime.now(timezone.utc) + expires_delta