CVE-2024-4577 kev+ ransomware in the critical feed json
Argument Injection in PHP-CGI
published 2024-06-09 2 y ago modified 2026-09-08 2 mo ago also BIT-libphp-2024-4577 , BIT-php-2024-4577 , BIT-php-min-2024-4577 , EUVD-2024-44188 , GHSA-3qgc-jrrr-25jv
- cvss
- 9.8
- version 3.1, CNA
- cisa kev
- Exploited
- added 2024-06-12, used in ransomware
- epss
- 100.0%
- EPSS 100.0% chance of exploitation in 30 days, percentile 99.9%
- public exploits
- 2
- Metasploit, Exploit-DB, plus a Nuclei check
Summary
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.
Patch / fix
cisa required action Apply mitigations per vendor instructions or discontinue use of the product if mitigations are unavailable.
- bitnami libphp 8.1.29, 8.2.20, 8.3.8
- bitnami php 8.1.29, 8.2.20, 8.3.8
- bitnami php-min 8.1.29, 8.2.20, 8.3.8
- PHP Group PHP 8.1.29, 8.2.20, 8.3.8
- php_group php 8.1.29, 8.2.20, 8.3.8
- php8 openSUSE Tumbleweed 8.3.12-1.1
opensuse advisories openSUSE-SU-2024:14376-1
- php81 Alpine 3.19 8.1.29-r0
- php82 Alpine 3.19 8.2.20-r0
- php83 Alpine 3.19 8.3.8-r0
alpine advisories ALPINE-CVE-2024-4577
Alpine secdb © Alpine Linux, from https://secdb.alpinelinux.org via OSV; changed: normalised to fixed package versions per release. CC BY-SA 4.0
- php CBL-Mariner 2.0 8.1.29-1
- php Azure Linux 3.0 8.3.8-1
azure linux advisories AZL-42424AZL-42433
Azure Linux vulnerability data, Copyright (c) Microsoft Corporation, from https://github.com/microsoft/AzureLinuxVulnerabilityData via OSV, under the MIT licence; changed: normalised to fixed package versions per release. MIT
- github.com/rapid7/metasploit-framework#19247 pull request
Vendor advisories
What the vendors themselves say about their products: affected, fixed or not affected, and what to do.
red hat product security vex CVE-2024-4577 updated cvss 9.8
php: Argument Injection in PHP-CGI
-
Red Hat Enterprise Linux 6 php, php-gd, php-cli, php-dba, php-fpm, php-pdo, +20 more Red Hat Enterprise Linux 7 php, php-gd, php-cli, php-dba, php-fpm, php-pdo, +18 more Red Hat Enterprise Linux 8 php, libzip, php-gd, php-cli, php-dba, php-dbg, +30 more Red Hat Enterprise Linux 9 php, php-gd, php-cli, php-dba, php-dbg, php-ffi, +18 more Red Hat Enterprise Linux 10 phpnot affected: vulnerable code not present
Red Hat CSAF VEX © Red Hat, Inc., from https://security.access.redhat.com/data/csaf/v2/vex/; changed: reduced to product statuses and remediations. CC BY 4.0 · csaf
Timeline
- First public exploit (Metasploit exploit/windows/http/php_cgi_arg_injection_rce_cve_2024_4577)
- Published
- Added to CISA KEV
- CISA SSVC: exploitation active
- CISA patch deadline
Known exploited
- Added
- 2 y ago
- Patch by
- 2024-07-03 (2 y ago)
- Ransomware
- Known to be used in ransomware campaigns
- Required action
- Apply mitigations per vendor instructions or discontinue use of the product if mitigations are unavailable.
- Vendor, product
- PHP Group, PHP
- CISA name
- PHP-CGI OS Command Injection Vulnerability
Ransomware
Groups reported to have exploited it in intrusions.
- TellYouThePass ransomware gang
reported by imperva.com
Ransomware Vulnerability Matrix by BushidoUK (github.com/BushidoUK/Ransomware-Vulnerability-Matrix), reformatted per CVE. CC BY 4.0
ATT&CK techniques
How it is exploited and what it leads to, in MITRE ATT&CK terms.
- T1190 Exploit Public-Facing Application exploitation
- T1059 Command and Scripting Interpreter primary impact
- T1003 OS Credential Dumping secondary impact
- T1003.001 LSASS Memory secondary impact
- T1033 System Owner/User Discovery secondary impact
- T1041 Exfiltration Over C2 Channel secondary impact
- T1053 Scheduled Task/Job secondary impact
- T1068 Exploitation for Privilege Escalation secondary impact
- T1071.001 Web Protocols secondary impact
- T1112 Modify Registry secondary impact
- T1543 Create or Modify System Process secondary impact
- T1570 Lateral Tool Transfer secondary impact
kev release 2025-07-28, att&ck v16.1. KEV to ATT&CK mappings by the MITRE Center for Threat-Informed Defense (Mappings Explorer, Apache-2.0). © 2026 The MITRE Corporation. This work is reproduced and distributed with the permission of The MITRE Corporation. Terms of use
CISA SSVC
- Exploitation
- Active, exploited in the wild
- Automatable
- yes
- Technical impact
- total
- Assessed
- 2 y ago
Exploit prediction
99.99% chance of exploitation in the next 30 days, higher than 99.9% of all scored CVEs (FIRST EPSS, 2026-11-08).
Exploits and checks
- Metasploit exploit/windows/http/php_cgi_arg_injection_rce_cve_2024_4577 PHP CGI Argument Injection Remote Code Execution metasploit exploit, excellent rank, 2024-06-06
- EDB-52331 PHP CGI Module 8.3.4 - Remote Code Execution (RCE) webapps, 2025-06-15
- Nuclei template PHP CGI - Argument Injection nuclei detection template
- github.com https://github.com/rapid7/metasploit-framework/pull/19247 referenced PoC, tagged "exploit" by a source, unverified
- github.com https://github.com/php/php-src/security/advisories/GHSA-3qgc-jrrr-25jv referenced PoC, tagged "exploit" by a source, unverified
- devco.re https://devco.re/blog/2024/06/06/security-alert-cve-2024-4577-php-cgi-argument-injection-vulnerability-en/ referenced PoC, tagged "exploit" by a source, unverified
- arstechnica.com https://arstechnica.com/security/2024/06/php-vulnerability-allows-attackers-to-run-malicious-code-on-windows-servers/ referenced PoC, tagged "exploit" by a source, unverified
- github.com https://github.com/11whoami99/CVE-2024-4577 referenced PoC, tagged "exploit" by a source, unverified
- github.com https://github.com/xcanwin/CVE-2024-4577-PHP-RCE referenced PoC, tagged "exploit" by a source, unverified
- labs.watchtowr.com https://labs.watchtowr.com/no-way-php-strikes-again-cve-2024-4577/ referenced PoC, tagged "exploit" by a source, unverified
- github.com https://github.com/watchtowrlabs/CVE-2024-4577 referenced PoC, tagged "exploit" by a source, unverified
- isc.sans.edu https://isc.sans.edu/diary/30994 referenced PoC, tagged "exploit" by a source, unverified
- vicarius.io https://www.vicarius.io/vsociety/posts/php-cgi-os-command-injection-vulnerability-cve-2024-4577 referenced PoC, tagged "exploit" by a source, unverified
- vicarius.io https://www.vicarius.io/vsociety/posts/php-cgi-argument-injection-to-rce-cve-2024-4577 referenced PoC, tagged "exploit" by a source, unverified
- blog.talosintelligence.com https://blog.talosintelligence.com/new-persistent-attacks-japan/ referenced PoC, tagged "exploit" by a source, unverified
CVSS scores
| assigned by | version | score | vector |
|---|---|---|---|
| CNA | 3.1 | 9.8 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H |
| NVD | 3.1 | 9.8 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H |
| OSV | 3.1 | 9.8 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H |
Affected packages
| ecosystem | package | affected | fixed in |
|---|---|---|---|
| bitnami | libphp | <8.1.29 >=8.2.0, <8.2.20 >=8.3.0, <8.3.8 |
8.1.29 8.2.20 8.3.8 |
| bitnami | php | <8.1.29 >=8.2.0, <8.2.20 >=8.3.0, <8.3.8 |
8.1.29 8.2.20 8.3.8 |
| bitnami | php-min | <8.1.29 >=8.2.0, <8.2.20 >=8.3.0, <8.3.8 |
8.1.29 8.2.20 8.3.8 |
Affected products
- PHP Group PHP
- php_group php
Classification
- Weakness
-
- CWE-78 Improper Neutralization of Special Elements used in an OS Command
- Technology feeds
References
-
github.com
/rapid7/metasploit-framework/pull/19247
exploit, issue-tracking, patch
-
github.com
/php/php-src/security/advisories/GHSA-3qgc-jrrr-25jv
exploit, third-party-advisory, advisory
-
devco.re
/blog/2024/06/06/security-alert-cve-2024-4577-php-cgi-argument-injection-vulnerability-en/
exploit, third-party-advisory, advisory
-
arstechnica.com
/security/2024/06/php-vulnerability-allows-attackers-to-run-malicious-code-on-windows-servers/
exploit, press/media-coverage, third-party-advisory, advisory
-
github.com
/11whoami99/CVE-2024-4577
exploit, evidence
-
github.com
/xcanwin/CVE-2024-4577-PHP-RCE
exploit, third-party-advisory, advisory
-
labs.watchtowr.com
/no-way-php-strikes-again-cve-2024-4577/
exploit, third-party-advisory, advisory
-
github.com
/watchtowrlabs/CVE-2024-4577
exploit, third-party-advisory, advisory
-
isc.sans.edu
/diary/30994
exploit, third-party-advisory, advisory
-
vicarius.io
/vsociety/posts/php-cgi-os-command-injection-vulnerability-cve-2024-4577
exploit, third-party-advisory, advisory
-
vicarius.io
/vsociety/posts/php-cgi-argument-injection-to-rce-cve-2024-4577
exploit, third-party-advisory, advisory
-
blog.talosintelligence.com
/new-persistent-attacks-japan/
exploit, third-party-advisory, advisory
-
blog.orange.tw
/2024/06/cve-2024-4577-yet-another-php-rce.html
third-party-advisory, advisory
-
imperva.com
/blog/imperva-protects-against-critical-php-vulnerability-cve-2024-4577/
third-party-advisory, advisory
-
php.net
/ChangeLog-8.php#8.1.29
release-notes, article
-
php.net
/ChangeLog-8.php#8.2.20
release-notes, article
-
php.net
/ChangeLog-8.php#8.3.8
release-notes, article
-
cert.be
/en/advisory/warning-php-remote-code-execution-patch-immediately
third-party-advisory, advisory
-
openwall.com
/lists/oss-security/2024/06/07/1
mailing-list, third-party-advisory, advisory
-
lists.fedoraproject.org
/archives/list/package-announce@lists.fedoraproject.org/message/PKGTQUOA2NTZ3RXN22CSAUJPIRUYRB4B/
mailing-list, discussion
-
lists.fedoraproject.org
/archives/list/package-announce@lists.fedoraproject.org/message/W45DBOH56NQDRTOM2DN2LNA2FZIMC3PK/
mailing-list, discussion
-
security.netapp.com
/advisory/ntap-20240621-0008/
third-party-advisory, advisory
-
cisa.gov
/known-exploited-vulnerabilities-catalog?field_cve=CVE-2024-4577
government-resource, us-government-resource, web
-
nvd.nist.gov
/vuln/detail/CVE-2024-4577
web
Sources
- CVE List CVE-2024-4577
- NVD CVE-2024-4577
- OSV BIT-libphp-2024-4577
- OSV BIT-php-2024-4577
- OSV BIT-php-min-2024-4577
- Maintainer advisory GHSA-3qgc-jrrr-25jv
Fencer Vulns keeps one entry per vulnerability: the CVE id wins, then GHSA, and records that alias each other are merged, except that two CVEs always keep separate entries. The same data is available as JSON.
The maintainers of php/php-src published their own advisory on GitHub. Reviewed sources take precedence over it.
CPEs and fixed versions use Anchore's correction of NVD's data: Added CPE configurations because not yet analyzed by NVD.