What’s Vulnerable › Vulnerabilities
CVE-2023-32679: Remote Code Execution via unrestricted file extension in Craft CMS
- Severity: high (CVSS 7.2 v3.1)
- Exploited in the wild: not listed in CISA KEV
- EPSS: 1.8% probability of exploitation in the next 30 days
- Public exploit or detection template: yes
- Published: 2023-05-19 · updated 2026-06-17
- Weakness: CWE-74
Description
Craft CMS is an open source content management system. In affected versions of Craft CMS an unrestricted file extension may lead to Remote Code Execution. If the name parameter value is not empty string('') in the View.php's doesTemplateExist() -> resolveTemplate() -> _resolveTemplateInternal() -> _resolveTemplate() function, it returns directly without extension verification, so that arbitrary extension files are rendered as twig templates. When attacker with admin privileges on a DEV or an improperly configured STG or PROD environment, they can exploit this vulnerability to remote code execution. Code execution may grant the attacker access to the host operating system. This issue has been addressed in version 4.4.6. Users are advised to upgrade. There are no known workarounds for this vulnerability.
Affected products
- craftcms cms: from 4.0.0 before 4.4.6 — fixed in 4.4.6
How to fix
Upgrade to a fixed version: craftcms cms 4.4.6. Check the vendor advisory for mitigations.
References
- https://github.com/craftcms/cms/security/advisories/GHSA-vqxf-r9ph-cc9c
- https://github.com/craftcms/cms/security/advisories/GHSA-vqxf-r9ph-cc9c
Get alerted when CVE-2023-32679 or the next vulnerability affects your stack