Craft CMS: Authenticated RCE through Twig sandbox escape
High severity. Published 6 August 2026. Update craftcms/cms to the fixed version of your branch (5.10.7, 4.18.3): composer update craftcms/cms.
Which versions are affected?
| Package | Affected versions | Fixed in |
|---|---|---|
| craftcms/cms (opens in a new tab) | >= 5.0.0-RC1, < 5.10.7 | >= 4.0.0-RC1, < 4.18.3 | 5.10.7, 4.18.3 |
What should you do?
Update every affected package you use to its fixed version, then check that nothing else in your project matches an advisory. To see which version you run, and whether anything is still affected:
composer show craftcms/cms
composer auditAdvisory details
| Severity | High |
|---|---|
| Published | |
| Updated | |
| CVE | CVE-2026-72781 (opens in a new tab) |
| GHSA | GHSA-f5wm-88jv-g5hx (opens in a new tab) |
| Weakness | CWE-693 |
What the advisory says
The Twig sandbox mechanism in Craft CMS is configured to allow dangerous functionality from the Yii framework, leading to authenticated RCE in a manner similar to previously disclosed vulnerabilities.
The Twig sandbox in Craft CMS works by implementing Twig's SecurityPolicyInterface. The resulting SecurityPolicy class implements the checkMethodAllowed and checkPropertyAllowed methods of the interface. The implementations compare whether the called method or property is in a configured allowlist or is marked with the AllowedInSandbox attribute.
Source: GHSA-f5wm-88jv-g5hx (opens in a new tab) in the GitHub Advisory Database (CC BY 4.0). Data from GitHub (opens in a new tab) as of .
Other recent advisories for this package
- Craft CMS: Passkey login accepts replayed WebAuthn assertions (critical, 7 August 2026)
- Craft CMS: Authorization bypass: view-only Categories user can modify category structure via structures/move-element (opens in a new tab) (medium, 6 August 2026)
- Craft CMS: Missing authorization check allows non-admin control panel users access to user registration metrics (opens in a new tab) (medium, 6 August 2026)
- Craft CMS: Arbitrary user password reset leading to administrator account takeover (high, 6 August 2026)
- Craft CMS: Missing authorization check allows non-admin control panel users to reorder Global Sets (opens in a new tab) (medium, 6 August 2026)