Description
pac4j-jwt versions prior to 4.5.9, 5.7.9, and 6.3.3 contain an authentication bypass vulnerability in JwtAuthenticator when processing encrypted JWTs that allows remote attackers to forge authentication tokens. Attackers who possess the server's RSA public key can create a JWE-wrapped PlainJWT with arbitrary subject and role claims, bypassing signature verification to authenticate as any user including administrators.
Problem types
CWE-347 Improper Verification of Cryptographic Signature
Product status
4.0 (semver) before 4.5.9
5.0 (semver) before 5.7.9
6.0 (semver) before 6.3.3
Credits
CodeAnt AI Security
References
www.pac4j.org/...ty-advisory-pac4j-jwt-jwtauthenticator.html
www.codeant.ai/...pac4j-jwt-authentication-bypass-public-key
www.vulncheck.com/...-jwtauthenticator-authentication-bypass