CVE-2022-24828: composer Improper Input Validation
Vulnerability summary
CVE-2022-24828 is a high (CVSS 8.8) Improper Input Validation vulnerability in composer. EPSS estimates a 1.89% chance of exploitation in the next 30 days, higher than 79.1% of scored vulnerabilities.
Advisory lineage
Upstream 0 · Downstream 2 · Related 2Timeline
- 13-04-2022PublishedVulnerability first disclosed.
- 23-04-2025Last modifiedVulnerability information updated.
Description
Composer is a dependency manager for the PHP programming language. Integrators using Composer code to call `VcsDriver::getFileContent` can have a code injection vulnerability if the user can control the `$file` or `$identifier` argument. This leads to a vulnerability on packagist.org for example where the composer.json's `readme` field can be used as a vector for injecting parameters into hg/Mercurial via the `$file` argument, or git via the `$identifier` argument if you allow arbitrary data there (Packagist does not, but maybe other integrators do). Composer itself should not be affected by the vulnerability as it does not call `getFileContent` with arbitrary data into `$file`/`$identifier`. To the best of our knowledge this was not abused, and the vulnerability has been patched on packagist.org and Private Packagist within a day of the vulnerability report.
CVSS metrics
5 scores · 4 sources · 2 versions- CVE.orgCNA8.3HighCVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:C/C:H/I:H/A:HDiffers
- OSV · UbuntuEcosystem advisory · calculated8.8HighCVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
- OSV · DebianEcosystem advisory · calculated8.8HighCVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
EPSS trend
Probability
1.89%
Chance of exploitation in the next 30 days
Percentile
79%
Versus all other CVEs
30-day change
+0.01 pp
From 1.88% on 18-09-2026
Known exploited
Compare KEV catalogsNot in any of the 3 tracked catalogs.
Public exploits
0 foundNo public exploits indexed.
Weaknesses
CWE · root cause- CWE-20Improper Input ValidationThe product receives input or data, but it does not validate or incorrectly validates that the input has the properties that are required to process the data safely and correctly.
- CWE-88Improper Neutralization of Argument Delimiters in a Command ('Argument Injection')The product constructs a string for a command to be executed by a separate component in another control sphere, but it does not properly delimit the intended arguments, options, or switches within that command string.
Affected systems
Opensuse3 products
- php-composer2&distro=openSUSE Leap 15.4< 2.2.3-150400.3.3.1
- php-composer2&distro=openSUSE Tumbleweed< 2.3.5-1.1
- php-composer&distro=openSUSE Tumbleweed< 1.10.26-1.1
Composer1 product
- composer< 1.10.26 | ≥ 2.0.0, < 2.2.12 | ≥ 2.3, < 2.3.6
Debian1 product
- composer< 2.2.12-1
Fedoraproject1 product
- fedoraEOL34 | 35 | 36
Getcomposer1 product
- composer< 1.10.26 | ≥ 2.0.0, < 2.2.12 | ≥ 2.3.0, < 2.3.5
Suse1 product
- php-composer2&distro=SUSE Linux Enterprise Module for Web and Scripting 15 SP4< 2.2.3-150400.3.3.1
Tenable1 product
- tenable.sc< 5.21.0
Ubuntu1 product
- composer< 1.0.0~beta2-1ubuntu0.1~esm2 | < 1.6.3-1ubuntu0.1~esm2 | < 1.10.1-1ubuntu0.1~esm2 | < 2.2.6-2ubuntu4+esm1
8 vendors · 10 products
References
13 links- github.com/composer/composer/security/advisories/GHSA-x7cr-6qr6-2hh6X Refsource CONFIRMREPORTThird Party Advisory
- github.com/composer/composer/commit/2c40c53637c5c7e43fff7c09d3d324d632734709X Refsource MISCREPORTPatchThird Party Advisory