{"id":"CVE-2024-56145","published":"2024-12-18T21:15:08Z","modified":"2026-06-17T08:11:45Z","title":"Craft CMS Code Injection Vulnerability","vendor":"Craft CMS","product":"Craft CMS","tier":"core","eol":null,"description":{"text":"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.","provenance":"source","from":"NVD"},"summary":{"text":"Craft CMS contains a code injection flaw, classed as improper control of code generation, that affects installations where PHP's register_argc_argv setting is enabled in php.ini. An attacker with remote network access can achieve remote code execution through an unspecified vector, requiring no authentication or user interaction, provided that setting is on.","provenance":"ai","model":"claude-haiku-5-5","generatedAt":"2026-10-30T13:35:56Z"},"cvss":{"score":9.8,"severity":"CRITICAL","version":"3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","provenance":"source","from":"NVD"},"epss":{"score":0.97405,"percentile":0.99898,"date":"2026-10-29","provenance":"source"},"kev":{"dateAdded":"2025-06-02","dueDate":"2025-06-23","ransomware":false,"requiredAction":"Apply mitigations per vendor instructions, follow applicable BOD 22-01 guidance for cloud services, or discontinue use of the product if mitigations are unavailable.","notes":"https://github.com/craftcms/cms/security/advisories/GHSA-2p6p-9rc9-62j9 ; https://nvd.nist.gov/vuln/detail/CVE-2024-56145","provenance":"source"},"vulncheckKev":{"dateAdded":"2025-05-27","exploitedFirstSeen":"2025-05-27","ransomware":false,"evidence":[{"url":"https://www.trendmicro.com/en_us/research/25/e/earth-lamia.html","date":"2025-05-27"},{"url":"https://fortiguard.fortinet.com/outbreak-alert/earth-lamia-apt-attack","date":"2025-05-30"},{"url":"https://www.cisa.gov/sites/default/files/feeds/known_exploited_vulnerabilities.json","date":"2025-06-02"},{"url":"https://cyble.com/blog/weekly-cyble-vulnerability-blog/","date":"2025-06-10"},{"url":"https://assets.recordedfuture.com/insikt-report-pdfs/2025/cta-2025-0828.pdf","date":"2025-08-28"},{"url":"https://www.recordedfuture.com/research/h1-2025-malware-and-vulnerability-trends","date":"2025-08-28"},{"url":"https://cyble.com/resources/research-reports/global-cybersecurity-report/","date":"2025-12-11"},{"url":"https://www.loginsoft.com/reports/annually/vulnerability-intelligence-report-2025","date":"2026-01-20"},{"url":"https://wwv.vulncheck.com/2026-vulncheck-exploit-intelligence-report","date":"2026-02-25"}],"evidenceTotal":9,"provenance":"source"},"exploited":true,"otx":{"pulseCount":50,"pulses":[{"name":"Actively_Exploited_Kev | Oct 30, 2026","url":"https://otx.alienvault.com/pulse/6ae35d889ea92b4ce19c2680","created":"2026-10-29"},{"name":"Actively_Exploited_Kev | Oct 29, 2026","url":"https://otx.alienvault.com/pulse/6ae20c1db17e7057ae7d9ad1","created":"2026-10-28"},{"name":"Actively_Exploited_Kev | Oct 28, 2026","url":"https://otx.alienvault.com/pulse/6ae0ba7e0e2a97ff7b218819","created":"2026-10-27"},{"name":"Actively_Exploited_Kev | Oct 27, 2026","url":"https://otx.alienvault.com/pulse/6adf68b85c3e852f3c111d18","created":"2026-10-26"},{"name":"Actively_Exploited_Kev | Oct 24, 2026","url":"https://otx.alienvault.com/pulse/6adb740e397c3ad4799aa4cd","created":"2026-10-23"},{"name":"Actively_Exploited_Kev | Oct 23, 2026","url":"https://otx.alienvault.com/pulse/6ada236fcfba2dfa730ea482","created":"2026-10-22"},{"name":"Actively_Exploited_Kev | Oct 22, 2026","url":"https://otx.alienvault.com/pulse/6ad8d33a077cbb5cab524d80","created":"2026-10-21"},{"name":"Actively_Exploited_Kev | Oct 21, 2026","url":"https://otx.alienvault.com/pulse/6ad78130c4d1ac2be83a8b6d","created":"2026-10-20"},{"name":"Actively_Exploited_Kev | Oct 20, 2026","url":"https://otx.alienvault.com/pulse/6ad62f63c24a405a3423cc13","created":"2026-10-19"},{"name":"Actively_Exploited_Kev | Oct 19, 2026","url":"https://otx.alienvault.com/pulse/6ad4dda174e5797d0bd238b7","created":"2026-10-18"}],"provenance":"machine"},"cwes":[{"id":"CWE-94","name":"Improper Control of Generation of Code"}],"references":[{"url":"https://github.com/craftcms/cms/commit/82e893fb794d30563da296bca31379c0df0079b3","tags":["Patch"]},{"url":"https://github.com/craftcms/cms/security/advisories/GHSA-2p6p-9rc9-62j9","tags":["Vendor Advisory"]},{"url":"https://github.com/Chocapikk/CVE-2024-56145","tags":["Exploit"]},{"url":"https://www.cisa.gov/known-exploited-vulnerabilities-catalog?field_cve=CVE-2024-56145","tags":["US Government Resource"]}],"techniques":[{"id":"T1055","name":"Process Injection","tactics":["privilege-escalation","stealth"],"provenance":"source","basis":"ctid-kev","bases":["ctid-kev"],"basisDetail":"CTID Mappings Explorer KEV 07/28/2025 (ATT&CK 16.1); capability: Code Injection","mappingType":"exploitation_technique","evidence":[],"comment":"This vulnerability, which is dependent on the PHP configuration setting, \"register_argc_argv\" being enabled, can allow an attacker to craft a malicious HTTP request that CMS can process as legitimate, leading to remote code execution and, potentially, full system compromise.","confidence":"high"},{"id":"T1059","name":"Command and Scripting Interpreter","tactics":["execution"],"provenance":"source","basis":"ctid-kev","bases":["ctid-kev"],"basisDetail":"CTID Mappings Explorer KEV 07/28/2025 (ATT&CK 16.1); capability: Code Injection","mappingType":"primary_impact","evidence":[],"comment":"This vulnerability, which is dependent on the PHP configuration setting, \"register_argc_argv\" being enabled, can allow an attacker to craft a malicious HTTP request that CMS can process as legitimate, leading to remote code execution and, potentially, full system compromise.","confidence":"high"}],"reports":[],"affected":[{"ecosystem":"Packagist","package":"craftcms/cms","vulnerableRanges":[">=5.0.0-RC1, <5.5.2",">=4.0.0-RC1, <4.13.2",">=3.0.0, <3.9.14"],"patched":["5.5.2","4.13.2","3.9.14"],"from":["GHSA-2p6p-9rc9-62j9"],"provenance":"source"}],"advisories":[{"id":"GHSA-2p6p-9rc9-62j9","url":"https://github.com/advisories/GHSA-2p6p-9rc9-62j9","severity":"CRITICAL","ecosystem":"Packagist","package":"craftcms/cms","vulnerableRanges":[">=5.0.0-RC1, <5.5.2"],"patched":["5.5.2"],"provenance":"source","from":"GHSA"},{"id":"GHSA-2p6p-9rc9-62j9","url":"https://github.com/advisories/GHSA-2p6p-9rc9-62j9","severity":"CRITICAL","ecosystem":"Packagist","package":"craftcms/cms","vulnerableRanges":[">=4.0.0-RC1, <4.13.2"],"patched":["4.13.2"],"provenance":"source","from":"GHSA"},{"id":"GHSA-2p6p-9rc9-62j9","url":"https://github.com/advisories/GHSA-2p6p-9rc9-62j9","severity":"CRITICAL","ecosystem":"Packagist","package":"craftcms/cms","vulnerableRanges":[">=3.0.0, <3.9.14"],"patched":["3.9.14"],"provenance":"source","from":"GHSA"}],"euvd":{"id":"EUVD-2024-3545","url":"https://euvd.enisa.europa.eu/vulnerability/EUVD-2024-3545","exploited":true,"exploitedSince":"2025-06-02","provenance":"source"},"exploits":[],"exploitSources":{"pocGithub":{"count":3,"skipped":0,"earliest":"2024-12-20","earliestUrl":"https://github.com/Chocapikk/CVE-2024-56145","repos":[{"name":"Chocapikk/CVE-2024-56145","url":"https://github.com/Chocapikk/CVE-2024-56145","stars":48,"created":"2024-12-20"},{"name":"Sachinart/CVE-2024-56145-craftcms-rce","url":"https://github.com/Sachinart/CVE-2024-56145-craftcms-rce","stars":4,"created":"2024-12-22"},{"name":"hmhlol/craft-cms-RCE-CVE-2024-56145","url":"https://github.com/hmhlol/craft-cms-RCE-CVE-2024-56145","stars":0,"created":"2025-04-06"}]},"metasploit":[{"name":"Craft CMS Twig Template Injection RCE via FTP Templates Path","module":"exploit/linux/http/craftcms_ftp_template","type":"exploit","disclosureDate":"2024-12-19","url":"https://github.com/rapid7/metasploit-framework/blob/master/modules/exploits/linux/http/craftcms_ftp_template.rb"}],"nuclei":[{"id":"CVE-2024-56145","name":"Craft CMS - Remote Code Execution via Template Path Manipulation","severity":"critical","path":"http/cves/2024/CVE-2024-56145.yaml","url":"https://github.com/projectdiscovery/nuclei-templates/blob/main/http/cves/2024/CVE-2024-56145.yaml"}],"first":{"date":"2024-12-19","source":"Metasploit","url":"https://github.com/rapid7/metasploit-framework/blob/master/modules/exploits/linux/http/craftcms_ftp_template.rb"},"provenance":"source"},"exploitRefs":["https://github.com/Chocapikk/CVE-2024-56145"],"flow":[{"stage":"exploitation","techniques":["T1055"],"provenance":"source"},{"stage":"primary","techniques":["T1059"],"provenance":"source"}],"timeline":[{"date":"2024-12-18","kind":"published","label":"Published (NVD)","url":"https://nvd.nist.gov/vuln/detail/CVE-2024-56145","provenance":"source"},{"date":"2024-12-19","kind":"exploit-public","label":"First public exploit: Metasploit; later: PoC-in-GitHub 2024-12-20","url":"https://github.com/rapid7/metasploit-framework/blob/master/modules/exploits/linux/http/craftcms_ftp_template.rb","provenance":"source"},{"date":"2025-05-27","kind":"exploited-reported","label":"Exploitation first reported (VulnCheck KEV evidence)","url":"https://www.trendmicro.com/en_us/research/25/e/earth-lamia.html","provenance":"source"},{"date":"2025-06-02","kind":"kev","label":"Added to CISA KEV","url":"https://www.cisa.gov/known-exploited-vulnerabilities-catalog","provenance":"source"},{"date":"2025-06-02","kind":"euvd-exploited","label":"ENISA EUVD: exploited","url":"https://euvd.enisa.europa.eu/vulnerability/EUVD-2024-3545","provenance":"source"}],"speed":{"daysToPublicExploit":1,"firstExploitFrom":"Metasploit","daysToKev":166},"priority":{"score":69.8,"factors":[{"name":"In a KEV catalog","points":35.0,"detail":"listed in CISA KEV and VulnCheck KEV"},{"name":"Recent KEV listing","points":0.0,"detail":"added 521 days ago"},{"name":"Known ransomware use","points":0.0,"detail":"not known"},{"name":"EPSS percentile","points":19.98,"detail":"percentile 0.9990"},{"name":"Named in threat reports","points":0.0,"detail":"0 reports"},{"name":"Public exploit code","points":5.0,"detail":"1 NVD reference tagged Exploit; 3 PoC-in-GitHub repos; 1 Metasploit module; 1 nuclei template"},{"name":"Mentioned in OTX pulses","points":3.0,"detail":"50 pulses"},{"name":"CVSS severity","points":6.86,"detail":"base score 9.8"},{"name":"End-of-life product","points":0.0,"detail":"supported or unknown"}]},"lineage":{"familyId":"fam-craft-cms-cve-2023-41892","packageHistory":[{"cve":"CVE-2024-21622","published":"2024-01-03","fixed":"4.5.11","kev":false,"link":{"from":"CVE-2024-21622","to":"CVE-2024-56145","relation":"successor","confidence":"low","kind":"sequence","evidence":[{"kind":"version-step","provenance":"source","package":"Packagist:craftcms/cms","fromFixed":"3.9.6","toFixed":"3.9.14","daysApart":350}]}},{"cve":"CVE-2024-52293","published":"2024-11-13","fixed":"5.4.3","kev":false},{"cve":"CVE-2024-52291","published":"2024-11-13","fixed":"5.4.6","kev":false},{"cve":"CVE-2024-52292","published":"2024-11-13","fixed":"5.4.9","kev":false,"link":{"from":"CVE-2024-52292","to":"CVE-2024-56145","relation":"successor","confidence":"low","kind":"sequence","evidence":[{"kind":"version-step","provenance":"source","package":"Packagist:craftcms/cms","fromFixed":"4.12.8","toFixed":"4.13.2","daysApart":35},{"kind":"version-step","provenance":"source","package":"Packagist:craftcms/cms","fromFixed":"5.4.9","toFixed":"5.5.2","daysApart":35}]}},{"cve":"CVE-2024-56145","published":"2024-12-18","fixed":"5.5.2","kev":true},{"cve":"CVE-2025-23209","published":"2025-01-18","fixed":"5.5.8","kev":true,"link":{"from":"CVE-2024-56145","to":"CVE-2025-23209","relation":"successor","confidence":"medium","kind":"sequence","evidence":[{"kind":"version-step","provenance":"source","package":"Packagist:craftcms/cms","fromFixed":"4.13.2","toFixed":"4.13.8","daysApart":31},{"kind":"version-step","provenance":"source","package":"Packagist:craftcms/cms","fromFixed":"5.5.2","toFixed":"5.5.8","daysApart":31},{"kind":"similar","provenance":"machine","score":0.32,"basis":"same product + CWE + description similarity"}]}},{"cve":"CVE-2025-46731","published":"2025-05-05","fixed":"5.6.15","kev":false},{"cve":"CVE-2025-32432","published":"2025-04-25","fixed":"5.6.17","kev":true,"link":{"from":"CVE-2024-56145","to":"CVE-2025-32432","relation":"successor","confidence":"medium","kind":"sequence","evidence":[{"kind":"version-step","provenance":"source","package":"Packagist:craftcms/cms","fromFixed":"3.9.14","toFixed":"3.9.15","daysApart":128},{"kind":"similar","provenance":"machine","score":0.49,"basis":"same product + CWE + description similarity"}]}}],"package":"Packagist:craftcms/cms"}}