Skip to content

Commit

Permalink
Merge pull request #3 from cikupin/fix-jwt-expired
Browse files Browse the repository at this point in the history
fix jwt expired
  • Loading branch information
cikupin authored Nov 30, 2019
2 parents f29f63e + 25afcaa commit 6d77535
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion jwt.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ const JWTExpiration = 3600
func GenerateJWT(scope string, keyID string, secret string) (string, error) {
token := jwt.NewWithClaims(jwt.SigningMethodHS256, jwt.MapClaims{
"scope": scope,
"exp": JWTExpiration,
"exp": time.Now().Unix() + JWTExpiration,
})
token.Header = map[string]interface{}{
"alg": "HS256",
Expand Down

0 comments on commit 6d77535

Please sign in to comment.