{"items":[{"id":"NVI-00002716","kind":"vulnerability","title":"Twig: PHP code injection via `{% use %}` template name","revision":3,"unknowns":["Customer inventory, deployment, reachability and exploitation have not been inspected."],"lifecycle":"active","identifiers":["GHSA-7p85-w9px-jpjp","CVE-2026-46633"],"plain_summary":"OSV carries this publisher advisory for twig/twig. This is an aggregated source copy; consult the original publisher and compare update dates.","review_status":"source_listed","control_topics":[],"public_actions":[{"summary":"The original advisory lists fixed boundaries 3.26.0 for twig/twig. Confirm the publisher’s latest guidance.","source_ids":["sr-0ad046f11f66c45cdbaad290058ec0ec"],"action_type":"vendor_patch","limitations":"Confirm current vendor support, compatibility and deployment evidence. This report has not tested a fix in your system.","current_supported_target":null},{"summary":"Identify the exact component and deployed version, examine the linked publisher’s conditions, and retain evidence of any mitigation.","source_ids":["sr-57e90f66ee85ad3f69258f0922ef3dc0"],"action_type":"investigate","limitations":"Confirm current vendor support, compatibility and deployment evidence. This report has not tested a fix in your system.","current_supported_target":null}],"schema_version":"1.1.0","source_metrics":[{"kind":"EPSS","as_of":"2026-10-31T12:00:27.000Z","value":"0.688%","meaning":"FIRST EPSS model v2026.06.15; exploitation probability over 30 days, percentile 0.52733. Missing scores are unknown.","source_id":"sr-57e90f66ee85ad3f69258f0922ef3dc0"}],"why_it_matters":"Published affected context helps an owner decide what evidence to gather. This report has not examined your application.","related_sources":[{"id":"sr-0ad046f11f66c45cdbaad290058ec0ec","url":"https://github.com/advisories/GHSA-7p85-w9px-jpjp","basis":"vendor_advisory","notes":"GitHub-origin advisory, CC-BY-4.0; OSV is an aggregate copy, not independent corroboration.","title":"GHSA-7p85-w9px-jpjp","publisher":"GitHub Advisory Database via OSV","observed_at":"2026-11-04T23:35:38.163Z"},{"id":"sr-57e90f66ee85ad3f69258f0922ef3dc0","url":"https://www.first.org/epss/data.html","basis":"official_catalog","notes":"FIRST EPSS; probability of exploitation in the next 30 days, not local compromise. Dataset date/model retained; FIRST services terms apply.","title":"CVE-2026-46633","publisher":"FIRST EPSS","observed_at":"2026-10-31T22:06:15.379Z"}],"affected_context":[{"certainty":"source_listed","source_ids":["sr-0ad046f11f66c45cdbaad290058ec0ec"],"technology":"twig/twig","known_exclusions":[],"conditions_summary":"### Description\n\n`Compiler::string()` escapes `\"`, `$`, `\\`, NUL and TAB when generating PHP double-quoted string literals, but does not escape single quotes. In `ModuleNode::compileConstructor()`, the template name from a `{% use %}` tag is compiled via `subcompile()` -> `string()` and placed inside a surrounding PHP single-quoted string literal. A template name containing a single quote terminates that surrounding string early, allowing arbitrary PHP expressions to be injected into the compiled cache file.\n\nThe injected code executes within the PHP process when the cache file is first loaded, bypassing the Twig sandbox entirely and achieving remote code execution. `SecurityPolicy` unconditionally allows `{% use %}` regardless of the configured `allowedTags`, so this primitive is reachable from sandboxed templates as well.\n\n### Resolution\n\n`Compiler::string()` now also escapes single quotes so that template names placed inside single-quoted PHP literals can no longer break out of the surrounding context.\n\n### Credits\n\nTwig would like to thank Anvil Secure in collaboration with Claude and Anthropic Research for reporting the issue and providing the fix.","public_affected_ranges":["ECOSYSTEM: introduced 1.15.1; fixed 3.26.0"]}],"null_published_at":"2026-11-06T15:18:17.701Z","source_updated_at":"2026-11-04T00:15:05.269Z","source_disclosed_at":"2026-05-21T21:24:53.000Z","is_synthetic_fixture":false,"null_last_reviewed_at":null,"public_change_summary":"Source facts changed; compare the preserved prior revision.","null_first_observed_at":"2026-10-31T21:41:59.952Z"},{"id":"NVI-00002716","kind":"vulnerability","title":"Twig: PHP code injection via `{% use %}` template name","revision":2,"unknowns":["Customer inventory, deployment, reachability and exploitation have not been inspected."],"lifecycle":"active","identifiers":["GHSA-7p85-w9px-jpjp","CVE-2026-46633"],"plain_summary":"OSV carries this publisher advisory for twig/twig. This is an aggregated source copy; consult the original publisher and compare update dates.","review_status":"source_listed","control_topics":[],"public_actions":[{"summary":"The original advisory lists fixed boundaries 3.26.0 for twig/twig. Confirm the publisher’s latest guidance.","source_ids":["sr-23ff0466526894810bb4c8d12e7517e5"],"action_type":"vendor_patch","limitations":"Confirm current vendor support, compatibility and deployment evidence. This report has not tested a fix in your system.","current_supported_target":null},{"summary":"Identify the exact component and deployed version, examine the linked publisher’s conditions, and retain evidence of any mitigation.","source_ids":["sr-57e90f66ee85ad3f69258f0922ef3dc0"],"action_type":"investigate","limitations":"Confirm current vendor support, compatibility and deployment evidence. This report has not tested a fix in your system.","current_supported_target":null}],"schema_version":"1.1.0","source_metrics":[{"kind":"EPSS","as_of":"2026-10-31T12:00:27.000Z","value":"0.688%","meaning":"FIRST EPSS model v2026.06.15; exploitation probability over 30 days, percentile 0.52733. Missing scores are unknown.","source_id":"sr-57e90f66ee85ad3f69258f0922ef3dc0"}],"why_it_matters":"Published affected context helps an owner decide what evidence to gather. This report has not examined your application.","related_sources":[{"id":"sr-23ff0466526894810bb4c8d12e7517e5","url":"https://github.com/advisories/GHSA-7p85-w9px-jpjp","basis":"vendor_advisory","notes":"GitHub-origin advisory, CC-BY-4.0; OSV is an aggregate copy, not independent corroboration.","title":"GHSA-7p85-w9px-jpjp","publisher":"GitHub Advisory Database via OSV","observed_at":"2026-10-31T21:41:59.952Z"},{"id":"sr-57e90f66ee85ad3f69258f0922ef3dc0","url":"https://www.first.org/epss/data.html","basis":"official_catalog","notes":"FIRST EPSS; probability of exploitation in the next 30 days, not local compromise. Dataset date/model retained; FIRST services terms apply.","title":"CVE-2026-46633","publisher":"FIRST EPSS","observed_at":"2026-10-31T22:06:15.379Z"}],"affected_context":[{"certainty":"source_listed","source_ids":["sr-23ff0466526894810bb4c8d12e7517e5"],"technology":"twig/twig","known_exclusions":[],"conditions_summary":"### Description\n\n`Compiler::string()` escapes `\"`, `$`, `\\`, NUL and TAB when generating PHP double-quoted string literals, but does not escape single quotes. In `ModuleNode::compileConstructor()`, the template name from a `{% use %}` tag is compiled via `subcompile()` -> `string()` and placed inside a surrounding PHP single-quoted string literal. A template name containing a single quote terminates that surrounding string early, allowing arbitrary PHP expressions to be injected into the compiled cache file.\n\nThe injected code executes within the PHP process when the cache file is first loaded, bypassing the Twig sandbox entirely and achieving remote code execution. `SecurityPolicy` unconditionally allows `{% use %}` regardless of the configured `allowedTags`, so this primitive is reachable from sandboxed templates as well.\n\n### Resolution\n\n`Compiler::string()` now also escapes single quotes so that template names placed inside single-quoted PHP literals can no longer break out of the surrounding context.\n\n### Credits\n\nTwig would like to thank Anvil Secure in collaboration with Claude and Anthropic Research for reporting the issue and providing the fix.","public_affected_ranges":["ECOSYSTEM: introduced 0; fixed 3.26.0"]}],"null_published_at":"2026-11-01T01:45:38.515Z","source_updated_at":"2026-09-10T03:50:46.236Z","source_disclosed_at":"2026-05-21T21:24:53.000Z","is_synthetic_fixture":false,"null_last_reviewed_at":null,"public_change_summary":"Dated EPSS estimate updated; this is not a new disclosure or proof of exploitation.","null_first_observed_at":"2026-10-31T21:41:59.952Z"},{"id":"NVI-00002716","kind":"vulnerability","title":"Twig: PHP code injection via `{% use %}` template name","revision":1,"unknowns":["Customer inventory, deployment, reachability and exploitation have not been inspected."],"lifecycle":"active","identifiers":["GHSA-7p85-w9px-jpjp","CVE-2026-46633"],"plain_summary":"OSV carries this publisher advisory for twig/twig. This is an aggregated source copy; consult the original publisher and compare update dates.","review_status":"source_listed","control_topics":[],"public_actions":[{"summary":"The original advisory lists fixed boundaries 3.26.0 for twig/twig. Confirm the publisher’s latest guidance.","source_ids":["sr-23ff0466526894810bb4c8d12e7517e5"],"action_type":"vendor_patch","limitations":"Confirm current vendor support, compatibility and deployment evidence. This report has not tested a fix in your system.","current_supported_target":null}],"schema_version":"1.1.0","source_metrics":[],"why_it_matters":"Published affected context helps an owner decide what evidence to gather. This report has not examined your application.","related_sources":[{"id":"sr-23ff0466526894810bb4c8d12e7517e5","url":"https://github.com/advisories/GHSA-7p85-w9px-jpjp","basis":"vendor_advisory","notes":"GitHub-origin advisory, CC-BY-4.0; OSV is an aggregate copy, not independent corroboration.","title":"GHSA-7p85-w9px-jpjp","publisher":"GitHub Advisory Database via OSV","observed_at":"2026-10-31T21:41:59.952Z"}],"affected_context":[{"certainty":"source_listed","source_ids":["sr-23ff0466526894810bb4c8d12e7517e5"],"technology":"twig/twig","known_exclusions":[],"conditions_summary":"### Description\n\n`Compiler::string()` escapes `\"`, `$`, `\\`, NUL and TAB when generating PHP double-quoted string literals, but does not escape single quotes. In `ModuleNode::compileConstructor()`, the template name from a `{% use %}` tag is compiled via `subcompile()` -> `string()` and placed inside a surrounding PHP single-quoted string literal. A template name containing a single quote terminates that surrounding string early, allowing arbitrary PHP expressions to be injected into the compiled cache file.\n\nThe injected code executes within the PHP process when the cache file is first loaded, bypassing the Twig sandbox entirely and achieving remote code execution. `SecurityPolicy` unconditionally allows `{% use %}` regardless of the configured `allowedTags`, so this primitive is reachable from sandboxed templates as well.\n\n### Resolution\n\n`Compiler::string()` now also escapes single quotes so that template names placed inside single-quoted PHP literals can no longer break out of the surrounding context.\n\n### Credits\n\nTwig would like to thank Anvil Secure in collaboration with Claude and Anthropic Research for reporting the issue and providing the fix.","public_affected_ranges":["ECOSYSTEM: introduced 0; fixed 3.26.0"]}],"null_published_at":"2026-10-31T22:00:33.901Z","source_updated_at":"2026-09-10T03:50:46.236Z","source_disclosed_at":"2026-05-21T21:24:53.000Z","is_synthetic_fixture":false,"null_last_reviewed_at":null,"public_change_summary":"First indexed by Null; source disclosure date is shown separately.","null_first_observed_at":"2026-10-31T21:41:59.952Z"}],"next_cursor":null,"snapshot_revision":"42594"}