Skip to main content
EPSS 0.7%top 50%

CVE-2026-7210: CWE-331 Insufficient entropy in Python Software Foundation CPython

0
High
Published: 06/05/2026 (06/05/2026, 10:55:22 UTC)
Source: CVE Database V5
Vendor/Project: Python Software Foundation
Product: CPython

Description

`xml.parsers.expat` and `xml.etree.ElementTree` use insufficient entropy for Expat hash-flooding protection, which allows a crafted XML document to trigger hash flooding.\r\n\r\nFully mitigating this vulnerability requires both updating libexpat to 2.8.0 or later and applying this patch.

CVSS v4.0

Score 6.3medium

Attack Vector
Network
Attack Complexity
High
Attack Requirements
None
Privileges Required
None
User Interaction
None
Vuln. Confidentiality
None
Vuln. Integrity
None
Vuln. Availability
Low
Subsq. Confidentiality
None
Subsq. Integrity
None
Subsq. Availability
None
CVSS:4.0/AV:N/AC:H/AT:N/PR:N/UI:N/VC:N/VI:N/VA:L/SC:N/SI:N/SA:N

Affected software

Python Software Foundation

CPython

Affected versions
>=0 <3.11.16>=3.12.0 <3.12.14>=3.13.0 <3.13.14>=3.14.0 <3.14.6>=3.15.0a1 <3.15.0b2
cpython
pkg:pypi/cpython
Affected versions
=3.14.0=3.15.0
GitHub Actionsmore threats →cve
CPython
pkg:github/CPython
Affected versions
>=0 <3.11.16>=3.12.0 <3.12.14>=3.13.0 <3.13.14>=3.14.0 <3.14.6>=3.15.0a1 <3.15.0b2

Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.

AI-Powered Analysis

Machine-generated threat intelligence

AILast updated: 08/12/2026, 13:13:54 UTC

Technical Analysis

The vulnerability CVE-2026-7210 in CPython arises from insufficient entropy in the hash-flooding protection mechanism of the xml.parsers.expat and xml.etree.ElementTree modules. This weakness allows an attacker to craft XML documents that can trigger hash flooding attacks. Effective mitigation requires both updating the underlying libexpat library to version 2.8.0 or later and applying a corresponding patch to CPython. No official remediation level or patch links are provided in the available data.

Potential Impact

An attacker can exploit this vulnerability by crafting XML documents that cause hash flooding, potentially leading to denial of service or degraded performance in applications parsing XML with the affected CPython modules. The CVSS 4.0 score is 6.3 (medium severity), indicating a network attack vector with high complexity and limited impact (low availability impact). There are no known exploits in the wild at this time.

Mitigation Recommendations

No official patch or remediation level is currently confirmed. Full mitigation requires updating libexpat to version 2.8.0 or later and applying a patch to CPython. Patch status is not yet confirmed — check the Python Software Foundation advisory for current remediation guidance.

Pro Console: star threats, build custom feeds, automate alerts via Slack, email & webhooks.Upgrade to Pro

Technical Details

Data Version
5.2
Assigner Short Name
PSF
Date Reserved
2026-04-27T14:43:40.042Z
Cvss Version
4.0
State
PUBLISHED

Threat ID: 6a021aa7cbff5d861043053d

Added to database: 05/11/2026, 18:06:31 UTC

Last enriched: 08/12/2026, 13:13:54 UTC

Last updated: 09/10/2026, 22:05:07 UTC

Views: 399

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 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

Breach by OffSeqOFFSEQFRIENDS — 25% OFF

Check if your credentials are on the dark web

Instant breach scanning across billions of leaked records. Free tier available.

Scan now
OffSeq TrainingCredly Certified

Lead Pen Test Professional

Technical5-day eLearningPECB Accredited
View courses