Craft CMS: RCE via missing cleanseConfig in FieldsController::actionRenderCardPreview
High severity. Published 9 July 2026. Update craftcms/cms to 5.9.14 or later: composer update craftcms/cms.
Which versions are affected?
| Package | Affected versions | Fixed in |
|---|---|---|
| craftcms/cms (opens in a new tab) | >= 5.5.0, <= 5.9.13 | 5.9.14 |
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-56382 (opens in a new tab) |
| GHSA | GHSA-86vw-x4ww-x467 (opens in a new tab) |
| Weakness | CWE-94 |
What the advisory says
The actionRenderCardPreview() method in FieldsController passes the fieldLayoutConfig POST parameter directly to Fields::createLayout() without calling Component::cleanseConfig(). This allows Yii2 event handler injection via on eventName keys in the config array, leading to arbitrary code execution.
This is the same vulnerability pattern that was fixed in GHSA-4484-8v2f-5748 (same file, fldComponent method correctly uses cleanseConfig), GHSA-qx2q-q59v-wf3j (EntryTypesController), and GHSA-2fph-6v5w-89hh (ElementIndexesController).
PoC
As an admin user with a valid session:
When the FieldLayout object is constructed, Yii2 processes the on init key as an event handler registration.
Source: GHSA-86vw-x4ww-x467 (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)