RCE in Microsoft Windows
CVE-2024-4577
In PHP versions 8.1.* before 8.1.29, 8.2.* before 8.2.20, 8.3.* before 8.3.8, when using Apache and PHP-CGI on Windows, if the system is set up to use certain code pages, Windows may use "Best-Fit" behavior to replace characters in command line given to Win32 API functions. PHP CGI module may misinterpret those characters as PHP options, which may allow a malicious user to pass options to PHP binary being run, and thus reveal the source code of scripts, run arbitrary PHP code on the server, etc.
Vulnerability class: Command Injection (OS Command Injection)
Published · last modified .
CVSS v3 metric
CVSS v3 base score 9.8 (Critical). Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H.
EPSS exploit prediction
EPSS: 1.000 (100.0th percentile), scored .
Very high probability of exploitation in the next 30 days — among the top 0.1% most-likely-to-be-exploited CVEs. 100th percentile — 100.0% of CVEs in the catalogue have a lower EPSS than this one. How to read EPSS.
EPSS over last 30 days · oldest: 1.000 · newest: 1.000 · change: 0.000
Affected products
- Microsoft Windows
- PHP
- PHP Group — versions 8.1.*, 8.2.*, 8.3.*
- Fedoraproject Fedora — versions 39, 40
Weakness classification (CWE)
CISA KEV (Known Exploited Vulnerabilities)
This CVE is on the CISA KEV catalog, added on . CISA KEV inclusion means CISA has confirmed in-the-wild exploitation; US federal agencies are required to remediate within a published due date.
BOD 22-01 due date: .
Required action: Apply mitigations per vendor instructions or discontinue use of the product if mitigations are unavailable.
Known ransomware campaign use: yes.
Public proof-of-concept exploits
References
- github.com/php/php-src/security/advisories/GHSA-3qgc-jrrr-25jv (Exploit, Third Party Advisory)
- blog.orange.tw/2024/06/cve-2024-4577-yet-another-php-rce.html (Third Party Advisory)
- devco.re/blog/2024/06/06/security-alert-cve-2024-4577-php-cgi-argument-injectio… (Exploit, Third Party Advisory)
- arstechnica.com/security/2024/06/php-vulnerability-allows-attackers-to-run-mali… (Exploit, Third Party Advisory, Press/Media Coverage)
- www.imperva.com/blog/imperva-protects-against-critical-php-vulnerability-cve-20… (Third Party Advisory)
- github.com/11whoami99/CVE-2024-4577 (Exploit)
- github.com/xcanwin/CVE-2024-4577-PHP-RCE (Exploit, Third Party Advisory)
- github.com/rapid7/metasploit-framework/pull/19247 (Exploit, Patch, Issue Tracking)
- labs.watchtowr.com/no-way-php-strikes-again-cve-2024-4577/ (Exploit, Third Party Advisory)
- github.com/watchtowrlabs/CVE-2024-4577 (Exploit, Third Party Advisory)
Frequently asked questions
- What is CVE-2024-4577?
- CVE-2024-4577 is a critical-severity vulnerability in Microsoft Windows, classified under OS Command Injection. CVSS score: 9.8/10. Published 2024-06-09.
- How severe is CVE-2024-4577?
- Critical severity. CVSS v3 base score is 9.8 out of 10.
- Is CVE-2024-4577 known to be exploited?
- Yes. CVE-2024-4577 is listed in the CISA Known Exploited Vulnerabilities catalog (added 2024-06-12), indicating it is being actively exploited. 191 public proof-of-concept repositories are indexed.