Twig is a template language for PHP. Starting in 1.15.1 and prior to 3.26.0, Compiler::string() does not escape single quotes when a template name from a {% use %} tag is placed inside a PHP single-quoted string literal, allowing a crafted template name to terminate the string and inject arbitrary PHP expressions into the compiled cache file. This issue is fixed in version 3.26.0.
{
"cna_assigner": "GitHub_M",
"cwe_ids": [
"CWE-94"
],
"osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/46xxx/CVE-2026-46633.json"
}{
"extracted_events": [
{
"range": [
{
"introduced": "1.15.1"
},
{
"fixed": "3.26.0"
}
],
"source": "AFFECTED_FIELD",
"strategy": "StringRangeExpression"
},
{
"range": [
{
"fixed": "679447fa29083043665482ccf7d64372472621b8"
}
],
"source": "REFERENCES_COMMIT"
},
{
"range": [
{
"fixed": "a2c6db7ea7d2c90923e6708019ec1442526d1c30"
}
],
"source": "REFERENCES_COMMIT"
},
{
"range": [
{
"fixed": "e9ff55f6910832428e48a35b2e0748189ad49ae3"
}
],
"source": "REFERENCES_COMMIT"
},
{
"original_tag": "v3.26.0",
"range": [
{
"fixed": "1fcae487b180d78e6351f4e0afa91f9eab96a2bc"
}
],
"source": "REFERENCES_TAG"
}
]
}