CVE-2026-72781
Received
Received - Intake
Remote Code Execution in Craft CMS via Twig Sandbox Bypass
Vulnerability report for CVE-2026-72781, including description, CVSS score, EPSS score, affected products, exploitability, helpful resources, and attack-flow context.
Publication date: 2026-08-11
Last updated on: 2026-08-11
Assigner: VulnCheck
Description
Description
Craft CMS versions >= 5.0.0-RC1 before 5.10.7 and >= 4.0.0-RC1 before 4.18.3 contain a remote code execution vulnerability in the Twig sandbox mechanism. Because Craft marks the ElementInterface as safe (via the AllowedInSandbox attribute) and the sandbox allowlisting extends to the entire class hierarchy (craft\base\Component up to yii\base\Component), an authenticated attacker with permission to access the control panel can render a malicious Twig template that abuses the yii\base\Component arbitrary function-call gadget to execute arbitrary code, even when the Twig sandbox is enabled via enableTwigSandbox().
CVSS Scores
EPSS Scores
| Probability: | |
| Percentile: |
Meta Information
Affected Vendors & Products
| Vendor | Product | Version / Range |
|---|---|---|
| craftcms | craft_cms | From 5.0.0-RC1 (inc) to 5.10.7 (exc) |
| craftcms | craft_cms | From 4.0.0-RC1 (inc) to 4.18.3 (exc) |
| craftcms | craft_cms | From 4.0.0-RC1 (inc) to 4.18.2 (inc) |
| craftcms | craft_cms | From 5.0.0-RC1 (inc) to 5.10.6 (inc) |
Helpful Resources
Exploitability
| CWE ID | Description |
|---|---|
| CWE-693 | The product does not use or incorrectly uses a protection mechanism that provides sufficient defense against directed attacks against the product. |