Skip to content

Commit

Permalink
now during the login process all providers send refresh token during …
Browse files Browse the repository at this point in the history
…the token fetching process
  • Loading branch information
feyruzb committed Jan 15, 2025
1 parent 4b6cc2e commit 06d2ed8
Showing 1 changed file with 14 additions and 5 deletions.
19 changes: 14 additions & 5 deletions web/server/codechecker_server/api/authentication.py
Original file line number Diff line number Diff line change
Expand Up @@ -222,11 +222,20 @@ def createLink(self, provider):
code_challenge_method='S256'
)

# Create authorization URL
url, state = session.create_authorization_url(
authorization_uri,
state=stored_state,
code_verifier=pkce_verifier
if provider == "google":
# each provider has different requirements for requesting refresh token
url, state = session.create_authorization_url(
url = authorization_uri,
state=stored_state,
code_verifier=pkce_verifier,
access_type='offline',
prompt='consent'
)
else:
url, state = session.create_authorization_url(
authorization_uri,
state=stored_state,
code_verifier=pkce_verifier
)
# inserting data in database
self.insertDataOauth(state=state,
Expand Down

0 comments on commit 06d2ed8

Please sign in to comment.