7.3High

CVE-2026-112307sqlparse through 0.6.0 PHP Code Injection via output_format='php'

andialbrecht sqlparse Published: (1 month ago)

Description

sqlparse through 0.6.0 contains a PHP code injection vulnerability that allows attackers to inject PHP expressions by supplying SQL text containing unescaped dollar signs. Attackers can embed ${expr} or {${expr}} sequences that OutputPHPFilter places in double-quoted strings, executing arbitrary PHP code when the generated snippet runs.

Weakness (CWE): CWE-94

Data: CVE.org, NVD, CISA KEV, FIRST EPSS, Ubuntu. Published as the sources state it, in English.

Affected products and versions

VendorProductVersions
andialbrecht sqlparse ≤ 0.6.0
sqlparse project sqlparse ≤ 0.6.0

References and patches