Notice Score pending
sqlparse PHP output code injection and format() denial of service
A Python tool that tidies database queries can stall or have code slipped in.
- First seen
—
Products
Mitigation
Update to sqlparse 0.6.1. No further security fixes are planned.
Summary
The sqlparse Python library does not escape dollar signs in its php output format, so injected PHP code can end up in the generated snippet. Its format() can also use excessive CPU on statements with many unclosed quotes and stall. The maintainer has ended the project and says no further security fixes are planned.
Affected when
- php output format in use
- format() with default options or the sqlformat command
Incidents by product: sqlparse