Algorithm Confusion Vulnerability Affects CJWT
CVE-2024-54150

Currently unrated

Key Information:

Vendor

cjwt

Vendor
CVE Published:
19 December 2024

Key facts: CVE-2024-54150 is a vulnerability in cjwt. No exploitation in the wild or public proof-of-concept has been recorded so far. Its EPSS score is 0.4%, the estimated probability of exploitation in the next 30 days.

What is CVE-2024-54150?

CVE-2024-54150 is an algorithm confusion vulnerability affecting the C JSON Web Token (JWT) implementation known as cjwt. JWTs are widely used in web applications for securely transmitting information between parties as a JSON object. This vulnerability arises from the system's failure to correctly verify the signature type, which allows attackers to exploit the ambiguity between signing methods. If attackers can manipulate the signing algorithm expected by the server, they may gain unauthorized access to applications relying on cjwt for authentication and authorization, undermining the security of organizations that implement this technology.

Technical Details

The core issue with CVE-2024-54150 lies in the improper distinction between HMAC signed tokens and those signed using asymmetric algorithms like RS256 or EC. An attacker can craft a token with the algorithm field ("alg") set to "HS256," while the server may expect a token signed with an asymmetric algorithm. If the server mistakenly applies the wrong verification method, such as interpreting a public key as an HMAC secret, the attacker could successfully bypass security measures. Specifically, in RSA, keys can be computed from certain signatures, while with Elliptic Curve (EC), two keys might be recoverable from a single signature, presenting further avenues for exploitation. This vulnerability has been corrected in version 2.3.0 of cjwt, and users are strongly advised to upgrade as there are no known workarounds.

Potential Impact of CVE-2024-54150

  1. Unauthorized Access: Attackers exploiting this vulnerability could gain unauthorized access to systems that rely on cjwt for authentication, potentially leading to sensitive data exposure and manipulation.

  2. Data Breaches: With control over the JWT verification process, attackers could access or alter confidential information, resulting in significant data breaches that could harm an organization's integrity and reputation.

  3. Compromise of System Integrity: Once inside a system, attackers could leverage their access to execute further malicious actions, including deploying malware or creating persistent backdoors, fundamentally altering the security posture of the affected organization.

References

Browse all analysed vulnerabilities ›

Timeline

  • Vulnerability published

.