Intel

AIKIDO-2026-19997

craftcms/cms is vulnerable to Remote Code Execution

Remote Code ExecutionGHSA-265m-7826-wjqm Published 3 days ago

82

High Risk

This Affects:

PHPcraftcms/cms
4.0.0 - 4.18.1
Fixed in 4.18.2
5.0.0 - 5.10.5
Fixed in 5.10.6
Are you affected? Scan for Free

TL;DR

Craft CMS cleanses the outer element-search condition array but re-decodes and merges the JSON in the condition config without cleansing it again. Yii special configuration keys hidden inside that JSON string survive the first cleanse and are interpreted as behavior and event configuration during field-layout creation. An authenticated control-panel user can inject these keys to execute operating-system commands as the web user. The fix re-cleanses the decoded configuration before it is applied.

Who does this affect?

You are affected if you are using a version that falls within the vulnerable range and authenticated control-panel users can submit element-search condition configuration.

Background info

craftcms/cms is vulnerable to Remote Code Execution in versions 4.0.0 - 4.18.1 and 5.0.0 - 5.10.5.

How to fix this

Upgrade the craftcms/cms library to the patch version.