CVE-2026-4224

Stack overflow parsing XML with deeply nested DTD content models

Published Mar 16, 2026 CVSS 4.0 · 6 Medium EPSS < 1% KEV · Not listed
Description
When an Expat parser with a registered ElementDeclHandler parses an inline
document type definition containing a deeply nested content model a C stack
overflow occurs.

Analysis

AI-generated

Technical impact

When an Expat parser with a registered ElementDeclHandler parses an inline document type definition containing a deeply nested content model, a C stack overflow occurs. This weakness is identified as CWE‑674 and CWE‑805.

Affected Systems

CPython from the Python Software Foundation is affected. No specific version numbers are listed in the provided data, so all releases prior to a fix may be vulnerable.

Risk and Exploitability

The CVSS score of 6 indicates medium severity. No EPSS score is available, and the vulnerability is not listed in CISA’s Known Exploited Vulnerabilities catalog. Based on the description, it is inferred that the attack vector could be local or remote via XML ingestion, requiring the ability to supply an XML document with a deeply nested DTD to the Expat parser.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Check CPython releases for a patch addressing CVE‑2026‑4224.
  • Upgrade to a CPython version that includes the fix once available.
  • Subscribe to Python Security Advisories to stay informed about patches.

Generated by OpenCVE AI on March 17, 2026 at 01:50 UTC.

Tracking

Sign in to view the affected projects.

Advisories

Source ID Title
Debian DLA Debian DLA DLA-4583-1 python3.9 security update
Ubuntu USN Ubuntu USN USN-8509-1 Python vulnerabilities
History
Type Values Removed Values Added
First Time appeared Python python
CPEs cpe:2.3:a:python:python:*:*:*:*:*:*:*:*
cpe:2.3:a:python:python:3.15.0:alpha1:*:*:*:*:*:*
cpe:2.3:a:python:python:3.15.0:alpha2:*:*:*:*:*:*
cpe:2.3:a:python:python:3.15.0:alpha3:*:*:*:*:*:*
cpe:2.3:a:python:python:3.15.0:alpha4:*:*:*:*:*:*
cpe:2.3:a:python:python:3.15.0:alpha5:*:*:*:*:*:*
cpe:2.3:a:python:python:3.15.0:alpha6:*:*:*:*:*:*
cpe:2.3:a:python:python:3.15.0:alpha7:*:*:*:*:*:*
Vendors & Products Python python
Metrics cvssV3_1

{'score': 5.9, 'vector': 'CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:H'}

cvssV3_1

{'score': 7.5, 'vector': 'CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H'}

Type Values Removed Values Added
First Time appeared Python
Python cpython
Vendors & Products Python
Python cpython
Type Values Removed Values Added
Weaknesses CWE-805
References
Metrics threat_severity

None

cvssV3_1

{'score': 5.9, 'vector': 'CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:H'}

threat_severity

Moderate

Type Values Removed Values Added
Weaknesses CWE-674
Metrics ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'none', 'Technical Impact': 'partial'}, 'version': '2.0.3'}

Type Values Removed Values Added
Description When an Expat parser with a registered ElementDeclHandler parses an inline document type definition containing a deeply nested content model a C stack overflow occurs.
Title Stack overflow parsing XML with deeply nested DTD content models
References
Metrics cvssV4_0

{'score': 6, 'vector': 'CVSS:4.0/AV:N/AC:L/AT:P/PR:L/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N'}

Weaknesses
  • CWE-674

    Uncontrolled Recursion

  • CWE-805

    Buffer Access with Incorrect Length Value

Sources

Status
PUBLISHED
Assigner
PSF
Published
Updated
Aug 13, 2026, 12:27 AM
Reserved
Mar 15, 2026, 6:10 PM
Status
Modified
Published
Mar 16, 2026, 6:16 PM
Modified
Aug 13, 2026, 1:16 AM
Severity
Moderate
Public date
Mar 16, 2026, 5:52 PM