Craftcms cms
RCE when PHP `register_argc_argv` config setting is enabled in craftcms/cms
Craft is a flexible, user-friendly CMS for creating custom digital experiences on the web and beyond. Users of affected versions are affected by this vulnerability if their php.ini configuration has `register_argc_argv` enabled. For these users an unspecified remote code execution vector is present. Users are advised to update to version 3.9.14, 4.13.2, or 5.5.2. Users unable to upgrade should disable `register_argc_argv` to mitigate the issue.
Affected versions and mitigation
From the CVE record, GitHub Security Advisories and the vendor's references.Affected
- >= 5.0.0-RC1, < 5.5.2
Fixed in 5.5.2
from GitHub Security Advisory GHSA-2p6p-9rc9-62j9
- >= 4.0.0-RC1, < 4.13.2
Fixed in 4.13.2
from GitHub Security Advisory GHSA-2p6p-9rc9-62j9
- >= 3.0.0, < 3.9.14
Fixed in 3.9.14
from GitHub Security Advisory GHSA-2p6p-9rc9-62j9
Mitigation
Upgrade craftcms/cms to 5.5.2 or later.
Upgrade craftcms/cms to 4.13.2 or later.
Upgrade craftcms/cms to 3.9.14 or later.
Timeline
Days relative to CVE publicationFirst public PoC 1.3 days after publication; added to CISA KEV 166 days after publication. First PoC: Chocapikk/CVE-2024-56145 (created 20 Dec 2024, found by us: backfilled).
PoC repositories
Found on GitHub.2 PoCs · 1 pending
PoCs 2
| Repository | Created | Stars | Assessment |
|---|---|---|---|
| Chocapikk/CVE-2024-56145 | 20 Dec 2024 +1.3 d | 48 | PoC
Flags · score 30
Below the suspicion threshold (50); does not change the assessment. |
| Sachinart/CVE-2024-56145-craftcms-rce | 22 Dec 2024 +3.6 d | 4 | PoC |
Pending 1
| Repository | Created | Stars | Assessment |
|---|---|---|---|
| hmhlol/craft-cms-RCE-CVE-2024-56145 | 6 Apr 2025 +109 d | 0 | Pending · repository exceeds size limit via PoC Index |
Only PoCs count toward the first-PoC date and the characteristics below. Do not run PoC code from unknown sources.
Other public exploits
Exploit-DB, Metasploit and nuclei count as public PoCs. Exploit-tagged references from the CVE record and NVD are links only. None of these are analysed by us.| Source | Title | Published | Found by us |
|---|---|---|---|
| Metasploit | Metasploit exploit: Craft CMS Twig Template Injection RCE via FTP Templates Path (exploit/linux/http/craftcms_ftp_template) | 29 Dec 2024 | 14 Nov 2026 |
| nuclei template | nuclei template: Craft CMS - Remote Code Execution via Template Path Manipulation | 29 Dec 2024 | 14 Nov 2026 |
PoC characteristics
What to hunt for in your logs · from 3 PoC reposGET /
- Query
--configPath=/kishore- Seen in
- 1 repo: Sachinart/CVE-2024-56145-craftcms-rce
- Evidence
- Sachinart/CVE-2024-56145-craftcms-rce/poc.py:100 Sachinart/CVE-2024-56145-craftcms-rce/poc.py:105
Regex
Generated from PoC characteristics; not yet reviewed. Matches the request path and query.
(?i)^/\?(?:.*&)?--configPath=/kishore
Suricata
Template generated from PoC characteristics. Review before deploying.
alert http any any -> $HOME_NET any (msg:"GG PoC-Monitor CVE-2024-56145 craftcms cms exploit attempt"; flow:established,to_server; http.method; content:"GET"; http.uri; content:"--configPath=/kishore"; reference:url,poc.griffinguard.io/cve/CVE-2024-56145; classtype:web-application-attack; sid:9349619; rev:1;)
Sigma
Template generated from PoC characteristics. Review before deploying.
title: craftcms cms exploit attempt (CVE-2024-56145)
id: gg-pocmon-cve-2024-56145-9349619
status: experimental
description: Request pattern taken from public PoCs for CVE-2024-56145. Generated, not reviewed.
references:
- https://poc.griffinguard.io/cve/CVE-2024-56145
logsource:
category: webserver
detection:
selection:
cs-method: GET
cs-uri-query|contains|all:
- '--configPath=/kishore'
condition: selection
falsepositives:
- Authorized vulnerability scanning
level: critical
tags:
- attack.initial_access
- attack.t1190
- cve.2024.56145