Missing signature verification of JWT
Last updated
Last updated
Rule ID: java_lang_jwt_verification_bypass
Applicable Languages: Java
Weakness ID: CWE-347
Neglecting to verify the signature of JSON Web Tokens (JWTs) undermines the security of an application. Signature verification is essential to validate the authenticity and integrity of JWTs. Without this verification, your application is vulnerable to token forgery and replay attacks, allowing attackers to manipulate or reuse tokens for unauthorized access.
Avoid using the parse()
method to handle JWTs, as it does not verify the token's signature, creating a significant security vulnerability.
Use the parseClaimsJws()
method when working with JWTs. This method verifies the signature, thereby protecting against the manipulation of token data.
To omit this rule during a scan, and to provide you with continuous 24/7 code-level scanning, you can employ our