The vulnerability exists in Craft CMS due to a failure to sanitize user-supplied configuration data in the assembleLayoutFromPost function located in src/services/Fields.php. This function takes a fieldLayout parameter from a POST request, decodes it from JSON, and then uses it to create a FieldLayout object via the createLayout function. The createLayout function, in turn, passes the configuration to Craft::createObject(). Without sanitization, an authenticated administrator can inject a malicious Yii2 behavior configuration into the fieldLayout parameter. This allows for the attachment of a behavior that can execute arbitrary system commands on the server, resulting in Remote Code Execution. The patch for this vulnerability, found in commit 395c64f0b80b507be1c862a2ec942eaacb353748, addresses the root cause by adding a call to ComponentHelper::cleanseConfig() within the assembleLayoutFromPost function. This ensures that any potentially malicious configuration is removed before it can be processed.