Skip to main content
Press slash or control plus K to focus the search. Use the arrow keys to navigate results and press enter to open a threat.
Reconnecting to live updates…

CVE-2024-37568: n/a

0
High
VulnerabilityCVE-2024-37568cvecve-2024-37568
Published: Sun Jun 09 2024 (06/09/2024, 00:00:00 UTC)
Source: CVE Database V5

Description

lepture Authlib before 1.3.1 has algorithm confusion with asymmetric public keys. Unless an algorithm is specified in a jwt.decode call, HMAC verification is allowed with any asymmetric public key. (This is similar to CVE-2022-29217 and CVE-2024-33663.)

AI-Powered Analysis

AILast updated: 11/03/2025, 18:02:04 UTC

Technical Analysis

CVE-2024-37568 is a vulnerability identified in lepture Authlib, a popular Python library used for authentication, specifically in handling JSON Web Tokens (JWT). The issue arises from an algorithm confusion flaw where, if the developer does not explicitly specify the cryptographic algorithm in the jwt.decode function, the library permits HMAC verification using any asymmetric public key. Normally, asymmetric algorithms (e.g., RSA, ECDSA) and symmetric algorithms (e.g., HMAC) require different key types and verification methods. This confusion allows an attacker to exploit the verification process by substituting keys or tokens, effectively bypassing the intended cryptographic protections. This vulnerability is similar to previously disclosed issues (CVE-2022-29217 and CVE-2024-33663) that also involved algorithm confusion attacks in JWT libraries. The CVSS v3.1 score of 7.5 reflects a high severity due to the vulnerability's network attack vector, low attack complexity, no privileges or user interaction required, and its impact on integrity. The flaw does not affect confidentiality or availability but allows attackers to forge or manipulate JWT tokens, potentially granting unauthorized access or elevated privileges within applications relying on Authlib for authentication. No known exploits have been reported in the wild yet, but the vulnerability demands prompt attention. The recommended fix is to upgrade to Authlib version 1.3.1 or later, where this issue is resolved, and to ensure that developers explicitly specify the expected algorithm in jwt.decode calls to prevent fallback to insecure verification methods.

Potential Impact

For European organizations, the impact of CVE-2024-37568 can be significant, especially for those relying on lepture Authlib in their authentication and authorization systems. The vulnerability allows attackers to forge or manipulate JWT tokens, which are commonly used for session management, API authentication, and single sign-on (SSO) implementations. Successful exploitation can lead to unauthorized access to sensitive systems, privilege escalation, and potential lateral movement within networks. This undermines the integrity of authentication mechanisms, potentially exposing confidential business data and critical infrastructure. Since the vulnerability does not require authentication or user interaction, it can be exploited remotely and at scale if the affected systems are exposed to the internet. European sectors such as finance, healthcare, government, and cloud service providers, which often use Python-based web frameworks and libraries, are at higher risk. The absence of known exploits in the wild provides a window for proactive mitigation, but the high severity score indicates that organizations should prioritize patching and code review to prevent compromise.

Mitigation Recommendations

1. Upgrade lepture Authlib to version 1.3.1 or later immediately, as this version contains the fix for the algorithm confusion vulnerability. 2. Review all jwt.decode calls in application code to ensure that the 'algorithms' parameter is explicitly specified, restricting accepted algorithms to those intended (e.g., ['RS256'] for RSA signatures). Avoid relying on default algorithm selection. 3. Implement strict input validation and token verification policies to detect and reject tokens with unexpected or unsupported algorithms. 4. Conduct code audits and penetration testing focused on JWT handling to identify any other potential misconfigurations or vulnerabilities. 5. Monitor authentication logs for anomalies such as unexpected token issuances or verification failures that could indicate exploitation attempts. 6. Educate developers on secure JWT usage patterns and the risks of algorithm confusion attacks. 7. If upgrading immediately is not feasible, consider implementing compensating controls such as web application firewalls (WAFs) with rules to detect suspicious JWT tokens or unusual authentication patterns. 8. Maintain an inventory of applications and services using Authlib to ensure comprehensive coverage of the mitigation efforts.

Need more detailed analysis?Get Pro

Technical Details

Data Version
5.2
Assigner Short Name
mitre
Date Reserved
2024-06-09T00:00:00.000Z
Cvss Version
3.1
State
PUBLISHED

Threat ID: 6908ed741c2a0078ae510267

Added to database: 11/3/2025, 5:59:16 PM

Last enriched: 11/3/2025, 6:02:04 PM

Last updated: 11/3/2025, 9:38:31 PM

Views: 4

Community Reviews

0 reviews

Crowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.

Sort by
Loading community insights…

Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.

Actions

PRO

Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.

Please log in to the Console to use AI analysis features.

Need enhanced features?

Contact root@offseq.com for Pro access with improved analysis and higher rate limits.

Latest Threats