PT-2026-76749 · Pypi · Sqlparse

CVE-2026-54284

·

Published

2026-08-17

·

Updated

2026-09-01

CVSS v4.0

8.7

High

VectorAV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N
Name of the Vulnerable Software and Affected Versions sqlparse versions prior to 0.6.0
Description sqlparse contains an issue where the construction of TokenList and subsequent string conversion repeatedly flatten nested token subtrees. This occurs when processing SQL with deep nesting, such as numerous parentheses or CASE WHEN chains, leading to quadratic CPU consumption. This behavior can be triggered via the sqlparse.parse(), sqlparse.format(), and sqlparse.split() functions. Even when internal depth and token limits are reached, the process of reaching those limits is superlinear, allowing a small malicious payload (e.g., 1-2 KB) to consume significant CPU resources for several seconds, potentially leading to a denial of service by exhausting available worker processes.
Recommendations Update sqlparse to version 0.6.0 or later.

Exploit

Fix

DoS

Found an issue in the description? Have something to add? Feel free to write us 👾

Weakness Enumeration

Related Identifiers

CVE-2026-54284
ECHO-5D2B-9E8C-BDEC
GHSA-PWGV-4X5Q-6M9F
OPENSUSE-SU-2026:11557-1
OPENSUSE-SU-2026:21690-1
PYSEC-2026-3699
SUSE-SU-2026:3762-1
SUSE-SU-2026:3906-1
SUSE-SU-2026:3907-1
SUSE-SU-2026:3910-1

Affected Products

Sqlparse