CVE-2023-30608 json
Parser contains an inefficient regular expression in sqlparse
published 2023-04-18 3 y ago modified 2026-06-17 4 mo ago also GHSA-rrm6-wvj7-cwh2 , PYSEC-2023-87 , EUVD-2023-0243
- cvss
- 5.5
- version 3.1, CNA
- cisa kev
- Not listed
- not in CISA's catalog
- epss
- 1.0%
- EPSS 1.0% chance of exploitation in 30 days, percentile 62%
- public exploits
- 0
- none known
Summary
sqlparse is a non-validating SQL parser module for Python. In affected versions the SQL parser contains a regular expression that is vulnerable to ReDoS (Regular Expression Denial of Service). This issue was introduced by commit `e75e358`. The vulnerability may lead to Denial of Service (DoS). This issues has been fixed in sqlparse 0.4.4 by commit `c457abd5f`. Users are advised to upgrade. There are no known workarounds for this issue.
Patch / fix
- pypi sqlparse 0.4.4
- sqlparse_project sqlparse 0.4.4
- sqlparse Debian 12 0.4.2-1+deb12u1
- sqlparse Debian 14, Debian 13 0.4.4-1
debian advisories DEBIAN-CVE-2023-30608
- sqlparse Ubuntu 18.04 LTS 0.2.4-0.1ubuntu0.1
- sqlparse Ubuntu 20.04 LTS 0.2.4-3ubuntu0.1
- sqlparse Ubuntu 22.04 LTS 0.4.2-1ubuntu0.22.04.1
ubuntu advisories UBUNTU-CVE-2023-30608
Ubuntu security data © Canonical Ltd., from https://github.com/canonical/ubuntu-security-notices via OSV; changed: normalised to fixed package versions per release. CC BY-SA 4.0
- foreman satellite utils 6.14, satellite capsule 6.14, satellite 6.14 3.7.0.9-1.el8sat
- foreman-cli satellite utils 6.14, satellite 6.14 3.7.0.9-1.el8sat
- foreman-ec2 satellite 6.14 3.7.0.9-1.el8sat
- rubygem-git satellite 6.14 1.18.0-1.el8sat
- puppet-agent satellite capsule 6.14, satellite 6.14 7.26.0-3.el8sat
- puppetserver satellite capsule 6.14, satellite 6.14 7.11.0-1.el8sat
- rubygem-rack satellite capsule 6.14, satellite 6.14 2.2.7-1.el8sat
- foreman-ovirt satellite 6.14 3.7.0.9-1.el8sat
red hat advisories RHSA-2023:6818RHSA-2023:4591
- protobuf SLE Module for Python 3 15 SP5, SLE Module for Public Cloud 15 SP5, SLE Module for Public Cloud 15 SP4 +17 more 25.1-150400.9.6.1
- python-py SLE Module for Python 3 15 SP6, SLE Module for Python 3 15 SP5, SLE Module for Public Cloud 15 SP4 +6 more 1.11.0-150400.12.7.2
- python-rsa SLE Module for Python 3 15 SP6, SLE Module for Python 3 15 SP5, SLE Module for Public Cloud 15 SP4 +6 more 4.9-150400.12.7.1
- python-cffi SLE Module for Python 3 15 SP6, SLE Module for Python 3 15 SP5, SLE Module for Public Cloud 15 SP4 +6 more 1.15.1-150400.8.7.2
- python-idna SLE Module for Python 3 15 SP6, SLE Module for Python 3 15 SP5, SLE Module for Public Cloud 15 SP4 +6 more 3.4-150400.11.6.1
- python-pytz SLE Module for Python 3 15 SP6, SLE Module for Python 3 15 SP5, SLE Module for Public Cloud 15 SP4 +6 more 2023.3-150400.6.6.1
- python-apipkg SLE Module for Python 3 15 SP6, SLE Module for Python 3 15 SP5, SLE Module for Public Cloud 15 SP4 +6 more 3.0.1-150400.12.6.1
- python-pyasn1 SLE Module for Python 3 15 SP6, SLE Module for Python 3 15 SP5, SLE Module for Public Cloud 15 SP4 +6 more 0.5.0-150400.12.7.2
suse advisories SUSE-RU-2024:1637-3SUSE-RU-2024:1637-2SUSE-RU-2024:1637-1SUSE-SU-2023:2787-1SUSE-SU-2023:2693-1SUSE-SU-2023:2619-1
- python-sqlparse openSUSE Tumbleweed 0.5.5-2.1
- python-sqlparse openSUSE Tumbleweed 0.4.4-1.1
opensuse advisories openSUSE-SU-2026:11221-1openSUSE-SU-2024:12957-1
Vendor advisories
What the vendors themselves say about their products: affected, fixed or not affected, and what to do.
red hat product security vex CVE-2023-30608 updated cvss 7.5
sqlparse: Parser contains a regular expression that is vulnerable to ReDOS (Regular Expression Denial of Service)
-
Red Hat Ansible Automation Platform 2 python-sqlparseaffected: no fix available
-
Red Hat OpenShift Container Platform 4 python2-sqlparse, python3-sqlparseaffected: no fix planned “Will not fix”
-
Red Hat OpenStack Platform 13 (Queens) python-sqlparseaffected: no fix planned “Out of support scope”
-
Red Hat OpenStack Platform 16.1 python3-sqlparse Red Hat OpenStack Platform 16.2 python3-sqlparseaffected: no fix planned “Will not fix”
-
Red Hat OpenStack Platform 17.0 python3-sqlparseaffected: no fix planned “Out of support scope”
-
Red Hat Satellite 6.14 for RHEL 8 python-sqlparse 0.4.4-1.el8pc, python39-sqlparse 0.4.4-1.el8pcfixed: vendor fix RHSA-2023:6818
-
Red Hat RHUI 4 for RHEL 8 python-sqlparse 0.4.4-1.0.1.el8ui, python39-sqlparse 0.4.4-1.0.1.el8uifixed: vendor fix RHSA-2023:4591
-
Red Hat Satellite 6.14 for RHEL 8 cjson 1.7.14-5.el8sat, katello 4.9.0-1.el8sat, libsolv 0.7.22-4.el8pc, libcomps 0.1.18-4.el8pc, python-idna 3.3-2.el8pc, candlepin 4.3.1-1.el8sat, +667 more Red Hat RHUI 4 for RHEL 8 rhui-tools 4.5.0.5-1.el8ui, rhui-installer 4.5.0.1-1.el8ui, rhui-tools-libs 4.5.0.5-1.el8ui, python-django 3.2.19-1.0.1.el8ui, python39-django 3.2.19-1.0.1.el8uinot affected: vulnerable code not present
Red Hat CSAF VEX © Red Hat, Inc., from https://security.access.redhat.com/data/csaf/v2/vex/; changed: reduced to product statuses and remediations. CC BY 4.0 · csaf
CISA SSVC
- Exploitation
- none
- Automatable
- no
- Technical impact
- partial
- Assessed
- 21 mo ago
Exploit prediction
0.98% chance of exploitation in the next 30 days, higher than 62% of all scored CVEs (FIRST EPSS, 2026-11-08).
CVSS scores
| assigned by | version | score | vector |
|---|---|---|---|
| CNA | 3.1 | 5.5 | CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H |
| NVD | 3.1 | 7.5 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H |
| GitHub | 3.1 | 5.5 | CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H |
Affected packages
| ecosystem | package | affected | fixed in |
|---|---|---|---|
| pypi | sqlparse | >=0.1.15, <0.4.4 |
0.4.4 |
Affected products
- andialbrecht sqlparse
Classification
- Weakness
-
- CWE-1333 Inefficient Regular Expression Complexity
References
-
github.com
/andialbrecht/sqlparse/commit/c457abd5f097dd13fb21543381e7cfafe7d31cfb
web, patch
-
github.com
/andialbrecht/sqlparse/commit/e75e35869473832a1eb67772b1adfee2db11b85a
web, patch
-
github.com
/andialbrecht/sqlparse/security/advisories/GHSA-rrm6-wvj7-cwh2
web, patch, vendor-advisory, advisory
-
owasp.org
/www-community/attacks/Regular_expression_Denial_of_Service_-_ReDoS
web, technical-description
-
lists.debian.org
/debian-lts-announce/2023/05/msg00017.html
web, mailing-list, third-party-advisory
-
lists.debian.org
/debian-lts-announce/2024/12/msg00022.html
web
-
nvd.nist.gov
/vuln/detail/CVE-2023-30608
advisory
-
github.com
/andialbrecht/sqlparse
package
-
github.com
/pypa/advisory-database/tree/main/vulns/sqlparse/PYSEC-2023-87.yaml
web
Sources
- CVE List CVE-2023-30608
- GitHub Advisory GHSA-rrm6-wvj7-cwh2
- NVD CVE-2023-30608
- OSV PYSEC-2023-87
Fencer Vulns keeps one entry per vulnerability: the CVE id wins, then GHSA, and records that alias each other are merged, except that two CVEs always keep separate entries. The same data is available as JSON.