Skip to content

Expired JWT causes misleading log message #426

Description

@ipatix

When the REST API is used with an expired JWT, the following warning:

Error while parsing JWT token

This is misleading and suggests that the JWT is submitted incorrectly, which is not the case. It would be nice if cc-backend reports expired JWTs as 'expired' or something similar, so admins know they have to renew the JWT.

Perhaps this can be obtained from the error here?

token, err := jwt.Parse(rawtoken, func(t *jwt.Token) (any, error) {

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions