Contao is vulnerable to remote code execution in template closures
Package
Affected versions
>= 4.0.0, < 4.13.57
>= 5.0.0-RC1, < 5.3.42
>= 5.4.0-RC1, < 5.6.5
Patched versions
4.13.57
5.3.42
5.6.5
Description
Published by the National Vulnerability Database
Nov 25, 2025
Published to the GitHub Advisory Database
Nov 25, 2025
Reviewed
Nov 25, 2025
Last updated
Nov 27, 2025
Impact
Backend users with precise control over the contents of template closures can execute arbitrary PHP functions that do not have required parameters.
Patches
Update to Contao 4.13.57, 5.3.42 or 5.6.5
Workarounds
Manually patch the
Contao\Template::once()method.Resources
https://contao.org/en/security-advisories/remote-code-execution-in-template-closures
References