PT-2026-76720

CVE-2026-59894

·

Published

2026-08-17

·

Updated

2026-10-23

Description by

CVSS 3.1
7.5
High
MetricsAV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
Name of the Vulnerable Software and Affected Versions sqlparse versions prior to 0.6.0
Description The sqlparse/filters/output.py module fails to escape existing backslashes before quotes when using output format='python' or output format='php' in the sqlparse.format() function and the corresponding sqlformat -l modes. This allows crafted SQL to neutralize the quote escaping mechanism, terminate the intended language string, and inject Python or PHP code into the generated snippet. Code execution occurs if a downstream consumer executes or imports the generated source. The issue is specifically tied to the Python output filter, which uses single-quoted strings, and the PHP output filter, which uses double-quoted strings.
Recommendations Update sqlparse to version 0.6.0. As a temporary workaround, avoid using the output format='python' and output format='php' parameters in the sqlparse.format() function and the sqlformat -l options.
Exploitability
Exploit
Fix
Impacts
Vendors
Affected products
Related identifiers
GHSA-3496-9G83-7V6X
CLEANSTART-2026-EC11110
CLEANSTART-2026-EP84615
CLEANSTART-2026-MQ51708
CLEANSTART-2026-VX89697
CLEANSTART-2026-ZF06742
ECHO-29A6-7992-DF6D
OESA-2026-4218
OESA-2026-4219
OESA-2026-4320
OPENSUSE-SU-2026:11557-1
OPENSUSE-SU-2026:21690-1
PYSEC-2026-3696
RHLW-2026-7CB565D499929657
SUSE-SU-2026:23561-1
SUSE-SU-2026:3762-1
SUSE-SU-2026:3906-1
SUSE-SU-2026:3907-1
SUSE-SU-2026:3910-1
Found an issue in the description? Have something to add? Feel free to write us 👾