CVE-2024-5585
A public proof of concept exists; no exploitation attested.
- Published2024-06-09
- Fixed in8.3.8 · 8.2.20 · 8.1.29
- WeaknessCWE-116 · CWE-78
Am I affected?
Debian, Ubuntu or Red Hat sometimes backport a fix without changing the upstream version number: such a version reads « to verify », never « affected ».With a domain, we read the version its public headers and pages expose. A distribution build can carry the fix under an older number.
Description
In PHP versions 8.1.* before 8.1.29, 8.2.* before 8.2.20, 8.3.* before 8.3.8, the fix for CVE-2024-1874 does not work if the command name includes trailing spaces. Original issue: when using proc_open() command with array syntax, due to insufficient escaping, if the arguments of the executed command are controlled by a malicious user, the user can supply arguments that would execute arbitrary commands in Windows shell.
Timeline
dates in UTC- 2024-06-0919:15CVE publishedNVD
Versions per branch
NVD · CISA-ADP · OSV| Branch | Affected | Fixed in | Source |
|---|---|---|---|
| 8.3 | ≥ 8.3.0, < 8.3.8 | 8.3.8 | NVD · CISA-ADP · OSV |
| 8.2 | ≥ 8.2.0, < 8.2.20 | 8.2.20 | NVD · CISA-ADP · OSV |
| 8.1 | ≥ 8.1.0, < 8.1.29 | 8.1.29 | NVD · CISA-ADP |
| 8.1 | < 8.1.29 | 8.1.29 | OSV |
| Branch | Affected | Fixed in | Source |
|---|---|---|---|
| 40.x | = 40 | no fix published | NVD |
as publishedRanges as NVD and OSV publish them; a distribution’s build can be fixed under an older number.
Products declared by the CNA1 product
As php, the CNA that assigned this CVE, declared them in the CVE record; versions as written.
- PHP Group PHPother versions: affected
https://github.com/php/php-srcplatforms: Windows
Affected- ≥ 8.1.*, < 8.1.29fixed in 8.1.29semver
- ≥ 8.2.*, < 8.2.20fixed in 8.2.20semver
- ≥ 8.3.*, < 8.3.8fixed in 8.3.8semver
Source: the CNA record (CVE Program), © The MITRE Corporation,CVE Terms of UseCVE recordupdated 2024-06-09
Distribution builds and vendor advisories
Packages from OSV.dev and products from the vendors' CSAF advisories.
version not verifiedVersions not verified: read as OSV.dev and the vendors publish them, not checked against each vendor's release list.
Packages
- phpAzure Linux:3all versions · fixed in 8.3.8-1
- phpAzure Linux:2all versions · fixed in 8.1.29-1
- php-8.1Wolfiall versions · fixed in 8.1.29-r0
- php-8.1Chainguardall versions · fixed in 8.1.29-r0
- php-8.2Wolfiall versions · fixed in 8.2.20-r0
- php-8.2Chainguardall versions · fixed in 8.2.20-r0
- php81Alpine:v3.19all versions · fixed in 8.1.29-r0
- php82Alpine:v3.19all versions · fixed in 8.2.20-r0
1 more package range on OSV.dev
Vendor advisories
- CVE-2024-5585 Red Hat Product Security
php: Arguments execute arbitrary commands in Windows shell
Fix
- Update PHP to 8.3.8 · 8.2.20 · 8.1.29
Detection
- Nuclei template
- none so far ProjectDiscovery
- Exploit-DB
- no entry Exploit-DB
- Proof of concept
- CISA-ADP (SSVC)PoC stated2024-07-16
- PoC-in-GitHubno public repository identifiedread 2026-11-08
- Metasploit modules
- none listed Metasploit Framework
Sources
- CISA-ADPSSVC decisionpoc2024-07-16
- CNACVSS 3.17.7known since 2026-10-23
- NVDCVSS 3.18.8read 2026-10-23
- CNAweakness (CWE)CWE-116, CWE-78known since 2026-10-23
- NVDweakness (CWE)CWE-116read 2026-10-23
- FIRST EPSSEPSS score28.8 %read 2026-11-09
- OSVaffected packages—
- GitHub Advisoriesadvisory—
Identifiers
- AZL-42427same flawAzure Linux · MIT
- AZL-42439same flawAzure Linux · MIT
- BIT-libphp-2024-5585same flawBitnami · Apache-2.0
- BIT-php-2024-5585same flawBitnami · Apache-2.0
- BIT-php-min-2024-5585same flawBitnami · Apache-2.0
- CGA-jv4q-p359-w7v3same flawChainguard · CC-BY-NC-ND-4.0
- CGA-mjpm-2qjw-28v3same flawChainguard · CC-BY-NC-ND-4.0
- CGA-q9m5-f977-g33gsame flawChainguard · CC-BY-NC-ND-4.0
- CGA-qgc7-7w5c-6ww6same flawChainguard · CC-BY-NC-ND-4.0
- EUVD-2024-46774same flawENISA EUVD · LicenseRef-ENISA-legal-notice
- GHSA-9fcc-425m-g385same flawGitHub Advisory Database · CC-BY-4.0
Technical details
- CVSS v3 Vector
- CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
- Published
- 2024-06-09
- Last Modified
- 2026-06-17
- NVD status
- Modified
- GitHub Advisory
- GHSA-9fcc-425m-g385
Frequently asked questions
What is CVE-2024-5585?
Is CVE-2024-5585 actively exploited?
What is the CVSS score for CVE-2024-5585?
Running PHP? Hear about its next vulnerability
Surveillance reads the versions in your stack — a domain, a lockfile or a list — checks each CVE against the ranges its sources publish, and alerts you when one you run is exploited or enters CISA KEV. A version it cannot read stays « version not verified ».
No credit card required · No monthly cap on website lookups · 250 API requests/month
Go further
- Following what attackers exploit right now? The CISA KEV additions of the month, with their patch deadlines.
- Running this software? Vulnerability monitoring alerts you to new vulnerabilities in your products.
Related vulnerabilities
Same product first, then the same vendor advisory and the same publication week.
Sources for this record
- CVE Program · CVE Program Terms of Use
- ENISA EU Vulnerability Database · ENISA legal notice §1.2 (reproduction authorised, provided the source is acknowledged)
- FIRST EPSS · EPSS terms of use (free use, attribution requested)
- GitHub Advisory Database · CC-BY-4.0 · GHSA-9fcc-425m-g385
- NVD · Public domain (17 U.S.C. § 105) for NVD-authored data; third-party content under its own terms
- OSV.dev · Per record, as its publisher states it: each row carries the label in sourceLicense when one is served
- Red Hat Product Security (CSAF and VEX) · CC-BY-4.0
- CISA Vulnrichment · CC0-1.0