We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4723377 commit 10d2bd5Copy full SHA for 10d2bd5
core/authentication/jwt_backend.go
@@ -33,6 +33,7 @@ func InitJWTAuthenticationBackend() *JWTAuthenticationBackend {
33
func (backend *JWTAuthenticationBackend) GenerateToken() string {
34
token := jwt.New(jwt.GetSigningMethod("RS256"))
35
token.Claims["exp"] = time.Now().Add(time.Hour * time.Duration(tokenDuration)).Unix()
36
+ token.Claims["iat"] = time.Now().Unix()
37
tokenString, _ := token.SignedString(backend.privateKey)
38
return tokenString
39
}
0 commit comments