CVE-2024-4340
Aliases:GHSA-2m57-hf25-phggPYSEC-2026-1940RHSA-2024:9984RHSA-2024:9986DEBIAN-CVE-2024-4340CGA-gfgr-vr95-32hhCGA-h998-2q4h-8w3hCGA-p9j8-39h4-w7p6
Advisory lineage Upstream: 0 Downstream: 12
Deferred
Published: 30 Apr 2024, 14:23
Last modified:03 Nov 2025, 22:05
Vulnerability Summary
Overall Risk (default)
medium
31/100 CVSS Score
7.5 HIGH
v3.1 (cve.org)
EPSS Score
3.24% LOW
3% probability -13.80%
KEV
Not listed
Ransomware
No reports
Public exploits
None found
Dark Web
Not detected
Timeline
30 Apr 2024, 14:23
Published
Vulnerability first disclosed
03 Nov 2025, 22:05
Last Modified
Vulnerability information updated
Description
Passing a heavily nested list to sqlparse.parse() leads to a Denial of Service due to RecursionError.
CVSS Metrics
- v3.1•HIGH•Score: 7.5CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
EPSS Trends
Current EPSS score: 3.24%• Percentile: 88%
Techniques & Countermeasures
- CWE-674•Uncontrolled Recursion
The product does not properly control the amount of recursion that takes place, consuming excessive resources, such as allocated memory or the program stack.
Affected Systems
- chainguard•kubeflow-pipelines-visualization-server
< 2.2.0-r0
- chainguard•py3-sqlparse
< 0.5.0-r0
- wolfi•kubeflow-pipelines-visualization-server
< 2.2.0-r0
- wolfi•py3-sqlparse
< 0.5.0-r0
- debian•sqlparse
< 0.4.1-1+deb11u1 | < 0.4.2-1+deb12u1 | < 0.5.0-1 | < 0.5.0-1
- PyPI•sqlparse
< 0.5.0
- redhat•python-sqlparse
< 0:0.4.1-2.el9ost | < 0:0.4.1-2.el8ost
- redhat•python3-sqlparse
< 0:0.4.1-2.el9ost | < 0:0.4.1-2.el8ost
References (20)
- https://research.jfrog.com/vulnerabilities/sqlparse-stack-exhaustion-dos-jfsa-2024-001031292/
- https://github.com/andialbrecht/sqlparse/commit/b4a39d9850969b4e1d6940d32094ee0b42a2cf03
- https://github.com/advisories/GHSA-2m57-hf25-phgg
- https://lists.debian.org/debian-lts-announce/2024/12/msg00022.html
- https://github.com/andialbrecht/sqlparse/security/advisories/GHSA-2m57-hf25-phgg
- https://nvd.nist.gov/vuln/detail/CVE-2024-4340
- https://github.com/andialbrecht/sqlparse
- https://research.jfrog.com/vulnerabilities/sqlparse-stack-exhaustion-dos-jfsa-2024-001031292
- https://pypi.org/project/sqlparse
- https://access.redhat.com/errata/RHSA-2024:9984
- https://access.redhat.com/security/updates/classification/#moderate
- https://bugzilla.redhat.com/show_bug.cgi?id=2278038
- https://security.access.redhat.com/data/csaf/v2/advisories/2024/rhsa-2024_9984.json
- https://access.redhat.com/security/cve/CVE-2024-4340
- https://www.cve.org/CVERecord?id=CVE-2024-4340
- https://access.redhat.com/errata/RHSA-2024:9986
- https://security.access.redhat.com/data/csaf/v2/advisories/2024/rhsa-2024_9986.json
- https://security-tracker.debian.org/tracker/CVE-2024-4340
- https://github.com/CVEProject/cvelistV5/tree/main/cves/2024/4xxx/CVE-2024-4340.json
- https://pypi.org/project/pip