Under some circumstances, the sandbox security checks are not run which allows user-contributed templates to bypass the sandbox restrictions.
The security issue happens when all these conditions are met:
include()
function which references a template name (like included.twig
) and not a Template
or TemplateWrapper
instance;include()
call but in a non-sandbox context (possible as the sandbox has been globally disabled).The patch ensures that the sandbox security checks are always run at runtime.
We would like to thank Fabien Potencier for reporting and fixing the issue.
{ "nvd_published_at": "2024-09-09T19:15:13Z", "cwe_ids": [ "CWE-693" ], "severity": "MODERATE", "github_reviewed": true, "github_reviewed_at": "2024-09-09T20:19:26Z" }