Skip to main content
EPSS 0.3%top 84%

CVE-2026-71491: CWE-400: Uncontrolled Resource Consumption in andialbrecht sqlparse

0
High
Published: 08/17/2026 (08/17/2026, 18:18:00 UTC)
Source: CVE Database V5
Vendor/Project: andialbrecht
Product: sqlparse

Description

CVE-2026-71491 is a high-severity vulnerability in the Python sqlparse module prior to version 0.6.0. The issue involves uncontrolled resource consumption due to the group_comments function repeatedly rescanning comment-only SQL statements, leading to quadratic CPU usage during parsing and formatting operations. This vulnerability can cause significant performance degradation when processing certain SQL inputs. The issue is fixed in sqlparse version 0.6.0.

CVSS v4.0

Score 8.7high

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

Affected software

andialbrecht

sqlparse

Affected versions
<0.6.0
sqlparse
pkg:pypi/sqlparse
Affected versions
<0.6.0

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: 09/24/2026, 06:46:06 UTC

Technical Analysis

The sqlparse Python module before version 0.6.0 contains an uncontrolled resource consumption vulnerability (CWE-400) in the group_comments function located in sqlparse/engine/grouping.py. This function repeatedly rescans comment-only statements before reaching the MAX_GROUPING_TOKENS guard, resulting in quadratic CPU consumption when using sqlparse.parse() or sqlparse.format(sql, strip_comments=True). This flaw can severely degrade performance and is addressed by updating to version 0.6.0.

Potential Impact

Exploitation of this vulnerability can cause excessive CPU usage, leading to denial of service or degraded performance in applications that parse or format SQL statements using vulnerable versions of sqlparse. There are no known exploits in the wild at this time.

Mitigation Recommendations

Upgrade sqlparse to version 0.6.0 or later, where this uncontrolled resource consumption issue has been fixed. No other mitigations are indicated.

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
GitHub_M
Date Reserved
2026-08-06T19:56:23.725Z
Cvss Version
4.0
State
PUBLISHED

Threat ID: 6a8347d7bf8831d53948726a

Added to database: 08/17/2026, 17:41:43 UTC

Last enriched: 09/24/2026, 06:46:06 UTC

Last updated: 10/01/2026, 14:51:09 UTC

Views: 69

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