mirror of
https://forgejo.merr.is/annika/jwtauth.git
synced 2025-12-11 12:43:14 -05:00
fix incorrect error checking for NBF (#47)
This commit is contained in:
parent
38b5b1fc41
commit
b14bfcd999
1 changed files with 1 additions and 1 deletions
|
|
@ -110,7 +110,7 @@ func VerifyRequest(ja *JWTAuth, r *http.Request, findTokenFns ...func(r *http.Re
|
||||||
return token, ErrExpired
|
return token, ErrExpired
|
||||||
} else if verr.Errors&jwt.ValidationErrorIssuedAt > 0 {
|
} else if verr.Errors&jwt.ValidationErrorIssuedAt > 0 {
|
||||||
return token, ErrIATInvalid
|
return token, ErrIATInvalid
|
||||||
} else if verr.Errors&jwt.ValidationErrorIssuedAt > 0 {
|
} else if verr.Errors&jwt.ValidationErrorNotValidYet > 0 {
|
||||||
return token, ErrNBFInvalid
|
return token, ErrNBFInvalid
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue