CVE-2026-59893
published high CVSS 3.1 · 7.5sqlparse: Inefficient Regex Handling of Dollar-Quoted SQL Literals Leads to ReDoS (Denial of Service)
Package status and fixes
| Distro / vendor | Release | Package / product | Publisher status | Fixed build | Source |
|---|---|---|---|---|---|
| andialbrecht | — | sqlparse< 0.6.0 | Affected | Not stated | GitHub_M |
| Ubuntu | bionic | sqlparse | Advisory build | 0.2.4-0.1ubuntu0.1+esm1 | USN-8808-1 |
| SUSE / openSUSE | SLE-15-SP4 | python3-sqlparsenoarch | Advisory build | 0.4.2-150300.23.1 | SUSE-SU-2026:3906-1 |
| Ubuntu | focal | sqlparse | Advisory build | 0.2.4-3ubuntu0.1+esm1 | USN-8808-1 |
| Ubuntu | jammy | sqlparse | Advisory build | 0.4.2-1ubuntu0.22.04.3 | USN-8808-1 |
| Ubuntu | noble | sqlparse | Advisory build | 0.4.4-1ubuntu0.2 | USN-8808-1 |
| Ubuntu | resolute | sqlparse | Advisory build | 0.5.4-1ubuntu0.1 | USN-8808-1 |
| SUSE / openSUSE | SLE-15-SP4 | python311-sqlparsenoarch | Advisory build | 0.4.4-150400.6.16.1 | SUSE-SU-2026:3910-1 |
Show 31 more entries
| Distro / vendor | Release | Package / product | Publisher status | Fixed build | Source |
|---|---|---|---|---|---|
| SUSE / openSUSE | SLE-15-SP5 | python3-sqlparsenoarch | Advisory build | 0.4.2-150300.23.1 | SUSE-SU-2026:3906-1 |
| SUSE / openSUSE | SLE-15-SP5 | python311-sqlparsenoarch | Advisory build | 0.4.4-150400.6.16.1 | SUSE-SU-2026:3910-1 |
| SUSE / openSUSE | SLE-15-SP6 | python3-sqlparsenoarch | Advisory build | 0.4.2-150300.23.1 | SUSE-SU-2026:3906-1 |
| SUSE / openSUSE | SLE-15-SP6 | python311-sqlparsenoarch | Advisory build | 0.4.4-150600.3.9.1 | SUSE-SU-2026:3907-1 |
| SUSE / openSUSE | SLE-15-SP7 | python2-sqlparsenoarch | Advisory build | 0.2.4-150100.6.11.1 | SUSE-SU-2026:3762-1 |
| SUSE / openSUSE | SLE-15-SP7 | python3-sqlparsenoarch | Advisory build | 0.4.2-150300.23.1 | SUSE-SU-2026:3906-1 |
| SUSE / openSUSE | SLE-15-SP7 | python311-sqlparsenoarch | Advisory build | 0.4.4-150600.3.9.1 | SUSE-SU-2026:3907-1 |
| SUSE / openSUSE | SLE-16 | python313-sqlparsenoarch | Advisory build | 0.5.3-160000.4.1 | SUSE-SU-2026:23561-1 |
| SUSE / openSUSE | SLE-3-SP7 | python311-sqlparsenoarch | Advisory build | 0.4.4-150600.3.9.1 | SUSE-SU-2026:3907-1 |
| SUSE / openSUSE | openSUSE-Leap-16.0 | python313-sqlparsenoarch | Advisory build | 0.5.3-160000.4.1 | OPENSUSE-SU-2026:21690-1 |
| SUSE / openSUSE | openSUSE-Tumbleweed | python313-sqlparseaarch64 | Advisory build | 0.6.0-1.1 | OPENSUSE-SU-2026:11557-1 |
| SUSE / openSUSE | openSUSE-Tumbleweed | python313-sqlparseppc64le | Advisory build | 0.6.0-1.1 | OPENSUSE-SU-2026:11557-1 |
| SUSE / openSUSE | openSUSE-Tumbleweed | python313-sqlparses390x | Advisory build | 0.6.0-1.1 | OPENSUSE-SU-2026:11557-1 |
| SUSE / openSUSE | openSUSE-Tumbleweed | python313-sqlparsex86_64 | Advisory build | 0.6.0-1.1 | OPENSUSE-SU-2026:11557-1 |
| SUSE / openSUSE | openSUSE-Tumbleweed | python314-sqlparseaarch64 | Advisory build | 0.6.0-1.1 | OPENSUSE-SU-2026:11557-1 |
| SUSE / openSUSE | openSUSE-Tumbleweed | python314-sqlparseppc64le | Advisory build | 0.6.0-1.1 | OPENSUSE-SU-2026:11557-1 |
| SUSE / openSUSE | openSUSE-Tumbleweed | python314-sqlparses390x | Advisory build | 0.6.0-1.1 | OPENSUSE-SU-2026:11557-1 |
| SUSE / openSUSE | openSUSE-Tumbleweed | python314-sqlparsex86_64 | Advisory build | 0.6.0-1.1 | OPENSUSE-SU-2026:11557-1 |
| Ubuntu | bionic | pypy-sqlparse | Advisory build | 0.2.4-0.1ubuntu0.1+esm1 | USN-8808-1 |
| Ubuntu | bionic | python-sqlparse | Advisory build | 0.2.4-0.1ubuntu0.1+esm1 | USN-8808-1 |
| Ubuntu | bionic | python3-sqlparse | Advisory build | 0.2.4-0.1ubuntu0.1+esm1 | USN-8808-1 |
| Ubuntu | bionic | sqlformat | Advisory build | 0.2.4-0.1ubuntu0.1+esm1 | USN-8808-1 |
| Ubuntu | focal | pypy-sqlparse | Advisory build | 0.2.4-3ubuntu0.1+esm1 | USN-8808-1 |
| Ubuntu | focal | python3-sqlparse | Advisory build | 0.2.4-3ubuntu0.1+esm1 | USN-8808-1 |
| Ubuntu | focal | sqlformat | Advisory build | 0.2.4-3ubuntu0.1+esm1 | USN-8808-1 |
| Ubuntu | jammy | python3-sqlparse | Advisory build | 0.4.2-1ubuntu0.22.04.3 | USN-8808-1 |
| Ubuntu | jammy | sqlformat | Advisory build | 0.4.2-1ubuntu0.22.04.3 | USN-8808-1 |
| Ubuntu | noble | python3-sqlparse | Advisory build | 0.4.4-1ubuntu0.2 | USN-8808-1 |
| Ubuntu | noble | sqlformat | Advisory build | 0.4.4-1ubuntu0.2 | USN-8808-1 |
| Ubuntu | resolute | python3-sqlparse | Advisory build | 0.5.4-1ubuntu0.1 | USN-8808-1 |
| Ubuntu | resolute | sqlformat | Advisory build | 0.5.4-1ubuntu0.1 | USN-8808-1 |
Description
sqlparse is a non-validating SQL parser module for Python. Prior to 0.6.0, SQL_REGEX in sqlparse/keywords.py and the per-position loop in sqlparse/lexer.py repeatedly scan unmatched dollar-quoted literal and multiline-comment delimiters, causing quadratic CPU consumption through sqlparse.parse(), sqlparse.format(), and sqlparse.split(). This issue is fixed in version 0.6.0.
Related advisories
Vendor advisories explicitly linked to this CVE.
Assessment
CVSS risk assessment and additional context for this vulnerability.
- CVSS version
- 3.1
- Base score
- 7.5 / 10
- Severity
- high
- Provider
- GitHub_M · cna
- Vector string
- CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
Publisher product statements
Version ranges and default statuses as reported by each provider.
| Vendor | Product | Version status | Source |
|---|---|---|---|
| andialbrecht | sqlparse | < 0.6.0 (affected) | GitHub_M · cna |
Weaknesses
1- CWE-1333 CWE-1333: Inefficient Regular Expression Complexity
References
2Provider assertions
2GitHub_M · cna
sqlparse: Inefficient Regex Handling of Dollar-Quoted SQL Literals Leads to ReDoS (Denial of Service)
CISA-ADP · adp
CISA ADP Vulnrichment
Provenance
- Schema
- 5.2
- Searchable
- yes
- Content hash
- 8429ebe8443b8d6fe23704f33112eaa05297a35c7ce4fe8b239f43b2ce932873
- Ingested
- 23 Sep 2026, 09:22:51 UTC
- Source record
- Official CVE record