fix: authorize endpoint setting user session

This commit is contained in:
Lakhan Samani
2022-08-29 08:18:20 +05:30
parent 5f385b2016
commit 97f6c7d50a
6 changed files with 7 additions and 6 deletions

View File

@@ -248,7 +248,7 @@ func AuthorizeHandler() gin.HandlerFunc {
return
}
memorystore.Provider.SetUserSession(user.ID, constants.TokenTypeSessionToken+"_"+newSessionTokenData.Nonce, newSessionToken)
memorystore.Provider.SetUserSession(sessionKey, constants.TokenTypeSessionToken+"_"+newSessionTokenData.Nonce, newSessionToken)
cookie.SetSession(gc, newSessionToken)
code := uuid.New().String()
memorystore.Provider.SetState(codeChallenge, code+"@"+newSessionToken)