diff --git a/AC_PKCE/API_server/auth.py b/AC_PKCE/API_server/auth.py index 9fd1f05..d44df7e 100644 --- a/AC_PKCE/API_server/auth.py +++ b/AC_PKCE/API_server/auth.py @@ -10,7 +10,7 @@ def verify_access_token(access_token): try: decoded_token = jwt.decode(access_token.encode(), public_key, issuer = ISSUER, - algorithm = 'RS256') + algorithms = 'RS256') except (jwt.exceptions.InvalidTokenError, jwt.exceptions.InvalidSignatureError, jwt.exceptions.InvalidIssuerError, diff --git a/AC_PKCE/auth_server/auth.py b/AC_PKCE/auth_server/auth.py index d349a0c..afff07e 100644 --- a/AC_PKCE/auth_server/auth.py +++ b/AC_PKCE/auth_server/auth.py @@ -43,8 +43,8 @@ def generate_access_token(): "exp": time.time() + JWT_LIFE_SPAN } - access_token = jwt.encode(payload, private_key, algorithm = 'RS256').decode() - + access_token = jwt.encode(payload, private_key, algorithm = 'RS256') + return access_token def generate_authorization_code(client_id, redirect_url, code_challenge):