CVE-2024-5642: Vulnerability in Python Software Foundation CPython
CPython 3.9 and earlier doesn't disallow configuring an empty list ("[]") for SSLContext.set_npn_protocols() which is an invalid value for the underlying OpenSSL API. This results in a buffer over-read when NPN is used (see CVE-2024-5535 for OpenSSL). This vulnerability is of low severity due to NPN being not widely used and specifying an empty list likely being uncommon in-practice (typically a protocol name would be configured).
AI Analysis
Technical Summary
The vulnerability in CPython 3.9 and earlier arises from allowing an empty list to be passed to SSLContext.set_npn_protocols(), which is not disallowed by CPython but is invalid for OpenSSL's API. This leads to a buffer over-read condition when NPN is enabled, as referenced by CVE-2024-5535 in OpenSSL. The issue is of medium severity (CVSS 6.5) due to network attack vector, low complexity, no privileges required, no user interaction, and limited confidentiality and availability impact. No known exploits are reported in the wild.
Potential Impact
The impact is a potential buffer over-read in CPython's SSL context when NPN is used with an empty protocol list, which could lead to limited information disclosure or application instability. However, since NPN is not widely used and configuring an empty list is unlikely in practice, the real-world risk is low to medium. There is no indication of privilege escalation or integrity impact.
Mitigation Recommendations
Patch status is not yet confirmed — check the Python Software Foundation advisory for current remediation guidance. Until a fix is available, avoid configuring an empty list for SSLContext.set_npn_protocols(). Given the low usage of NPN, disabling NPN or avoiding its use can mitigate exposure. Monitor official Python updates for patches addressing this issue.
CVE-2024-5642: Vulnerability in Python Software Foundation CPython
Description
CPython 3.9 and earlier doesn't disallow configuring an empty list ("[]") for SSLContext.set_npn_protocols() which is an invalid value for the underlying OpenSSL API. This results in a buffer over-read when NPN is used (see CVE-2024-5535 for OpenSSL). This vulnerability is of low severity due to NPN being not widely used and specifying an empty list likely being uncommon in-practice (typically a protocol name would be configured).
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
The vulnerability in CPython 3.9 and earlier arises from allowing an empty list to be passed to SSLContext.set_npn_protocols(), which is not disallowed by CPython but is invalid for OpenSSL's API. This leads to a buffer over-read condition when NPN is enabled, as referenced by CVE-2024-5535 in OpenSSL. The issue is of medium severity (CVSS 6.5) due to network attack vector, low complexity, no privileges required, no user interaction, and limited confidentiality and availability impact. No known exploits are reported in the wild.
Potential Impact
The impact is a potential buffer over-read in CPython's SSL context when NPN is used with an empty protocol list, which could lead to limited information disclosure or application instability. However, since NPN is not widely used and configuring an empty list is unlikely in practice, the real-world risk is low to medium. There is no indication of privilege escalation or integrity impact.
Mitigation Recommendations
Patch status is not yet confirmed — check the Python Software Foundation advisory for current remediation guidance. Until a fix is available, avoid configuring an empty list for SSLContext.set_npn_protocols(). Given the low usage of NPN, disabling NPN or avoiding its use can mitigate exposure. Monitor official Python updates for patches addressing this issue.
Technical Details
- Data Version
- 5.1
- Assigner Short Name
- PSF
- Date Reserved
- 2024-06-04T18:40:21.539Z
- Cvss Version
- 3.1
- State
- PUBLISHED
Threat ID: 68e54032a677756fc996bc83
Added to database: 10/7/2025, 4:30:42 PM
Last enriched: 4/22/2026, 5:44:25 AM
Last updated: 5/9/2026, 8:27:54 AM
Views: 364
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.