Craft CMS: Authenticated RCE via `condition.config` JSON cleanse bypass
High severity. Published 6 August 2026. Update craftcms/cms to the fixed version of your branch (5.10.6, 4.18.2): 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.6 | >= 4.0.0-RC1, < 4.18.2 | 5.10.6, 4.18.2 |
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-72778 (opens in a new tab) |
| GHSA | GHSA-265m-7826-wjqm (opens in a new tab) |
| Weakness | CWE-915 |
What the advisory says
Craft CMS has an authenticated remote code execution issue in the control panel element-search condition handling.
Craft cleans the outer request-controlled condition array with Component::cleanseConfig(), but Conditions::createCondition() later decodes and merges the JSON string in condition.config without re-running cleanseConfig() on the decoded/merged configuration.
Because condition.config is a JSON string during the first cleanse, Yii special config keys such as as ... and on ... can be hidden inside it. After JSON decoding, those keys reach FieldLayout object creation and are interpreted by Yii as behavior/event configuration.
Source: GHSA-265m-7826-wjqm (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: Authenticated RCE through Twig sandbox escape (high, 6 August 2026)