cbcvebase.
CVE-2021-32839
published 2021-09-20

CVE-2021-32839: sqlparse is a non-validating SQL parser module for Python. In sqlparse versions 0.4.0 and 0.4.1 there is a regular Expression Denial of Service in sqlparse…

PriorityP341high7.5CVSS 3.1
AVNACLPRNUINSUCNINAH
EPSS
2.13%
79.7th percentile
sqlparse is a non-validating SQL parser module for Python. In sqlparse versions 0.4.0 and 0.4.1 there is a regular Expression Denial of Service in sqlparse vulnerability. The regular expression may cause exponential backtracking on strings containing many repetitions of '\r\n' in SQL comments. Only the formatting feature that removes comments from SQL statements is affected by this regular expression. As a workaround don't use the sqlformat.format function with keyword strip_comments=True or the --strip-comments command line flag when using the sqlformat command line tool. The issues has been fixed in sqlparse 0.4.2.

Affected

8 ranges
VendorProductVersion rangeFixed in
andialbrechtsqlparse
debiansqlparse< sqlparse 0.4.2-1 (bookworm)sqlparse 0.4.2-1 (bookworm)
sqlparse_projectsqlparse>= 0 < 0.4.1-1+deb11u10.4.1-1+deb11u1
sqlparse_projectsqlparse>= 0 < 0.4.2-10.4.2-1
sqlparse_projectsqlparse>= 0 < 0.4.2-10.4.2-1
sqlparse_projectsqlparse>= 0 < 0.4.2-10.4.2-1
sqlparse_projectsqlparse>= 0.4.0 < 0.4.20.4.2
sqlparse_projectsqlparse>= 0.4.0 < 0.4.20.4.2

CVSS provenance

nvdv3.17.5HIGHCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
nvdv2.05.0MEDIUMAV:N/AC:L/Au:N/C:N/I:N/A:P
osv7.5HIGH
vendor_debian7.5HIGH
vendor_redhat7.5HIGH
Stop checking back — get the weekly exploitation signal.

Every Monday: what got weaponized or added to CISA KEV in the last seven days — each CVE cross-linked to its PoC, Nuclei template, and detection rule. Free, one email a week, unsubscribe in one click.