CVE-2024-9774: python-sql · Improper Neutralization of Escape, Meta, or Control Sequences
Affects python-sqlSource CVE Database V5
Not known to be exploited · CVSS 6.5 Medium.
Data as of 26 Oct 2026, 08:30 UTC
- EPSS
- 0.6% chance of exploitation in 30 days – higher than 52% of CVEsExploit Prediction Scoring System: the likelihood attackers will use this flaw soon.
CVSS:3.0/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:H/A:NExploitation evidence
Disclosed: evidence found.
CVE published 27 Dec 2024
Detectable: no evidence on record.
No public nuclei template indexed
Weaponised: 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 26 Oct 2026.
What to do
Affected software
| Product | Affected | Fixed in |
|---|---|---|
PyPIpython-sqlpkg:pypi/python-sqlOther 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
To mitigate CVE-2024-9774, organizations should first monitor for updates or patches from the python-sql maintainers and apply them promptly once available. Until patches are released, developers should avoid passing non-Expression inputs to unary operators or implement strict input validation and sanitization to ensure all inputs are properly escaped. Code audits focusing on the use of python-sql unary operators can identify risky usage patterns. Limiting the privileges of accounts and services that interact with the database reduces the potential impact of exploitation. Employing database-level access controls and query parameterization can further mitigate risks. Additionally, monitoring database logs for unusual query patterns or anomalies may help detect exploitation attempts. Organizations should also consider isolating critical database systems and enforcing network segmentation to limit exposure. Finally, educating developers about secure usage of SQL construction libraries and the risks of improper input handling is essential for long-term risk reduction.
Description
A vulnerability was found in python-sql where unary operators do not escape non-Expression.