CVE-2026-59894: andialbrecht sqlparse · Code Injection
Affects andialbrecht sqlparseSource CVE Database V5
Not known to be exploited · CVSS 6.2 Medium : upgrade to 0.6.0 when convenient.
Data as of 15 Nov 2026, 20:25 UTC
- EPSS
- 0.1% chance of exploitation in 30 days – higher than 2% of CVEsExploit Prediction Scoring System: the likelihood attackers will use this flaw soon.
- Patch
- Available – fixed in 0.6.0
CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:P/VC:N/VI:N/VA:N/SC:H/SI:H/SA:LExploitation evidence
Disclosed: evidence found.
CVE published 17 Aug 2026
Detectable: no evidence on record.
No public nuclei template indexed
Weaponized: no evidence on record.
No public exploit code indexed in Metasploit or Exploit-DB
Exploited in the wildExploited: no evidence on record.
Not in CISA KEV and no source reports exploitation
Observed by OffSeq MirageSeen by Mirage: no evidence on record.
No attack traffic recorded by OffSeq Mirage sensors
A missing step is not evidence of safety. Sources: cve.org (opens in a new tab), the Metasploit, Exploit-DB and nuclei-templates index as of 15 Nov 2026.
What to do
Upgrade andialbrecht sqlparse to 0.6.0.
Affected software
| Product | Affected | Fixed in |
|---|---|---|
| andialbrechtsqlparse | Affected
| Fixed in
|
PyPIsqlparsepkg:pypi/sqlparseOther threats | Affected
| Fixed in
|
Check your own hosts for these packages with threat-finder (opens in a new tab), our free open-source scanner.
AI-suggested
Upgrade sqlparse to version 0.6.0 or later, where this code injection vulnerability is fixed. No other mitigations are indicated by the vendor advisory.
Description
CVE-2026-59894 is a code injection vulnerability in the Python sqlparse module prior to version 0.6.0. The issue occurs in sqlparse/filters/output.py where backslashes before quotes are not properly escaped when using output_format='python' or 'php'. This allows crafted SQL input to terminate the generated string and inject arbitrary Python or PHP code if the generated source is executed or imported downstream. The vulnerability is fixed in version 0.6.0.