Improper escaping of command arguments on Windows leading to command injection
Impact
Windows users running Composer to install untrusted dependencies are affected and should definitely upgrade for safety. Other OSs and WSL are not affected.
Patches
1.10.23 and 2.1.9 fix the issue
Workarounds
None
Affected software
Click a technology to see all vulnerabilities affecting it.
| Platform | Package | Vulnerable versions | Fixed in |
|---|---|---|---|
| Composer package | composer/composer | < 1.10.23, >= 2.0.0-alpha1, < 2.1.9 | 1.10.23, 2.1.9 |
References
- https://github.com/composer/composer/security/advisories/GHSA-frqg-7g38-6gcf
- https://nvd.nist.gov/vuln/detail/CVE-2021-41116
- https://github.com/composer/composer/commit/ca5e2f8d505fd3bfac6f7c85b82f2740becbc0aa
- https://github.com/FriendsOfPHP/security-advisories/blob/master/composer/composer/CVE-2021-41116.yaml
- https://github.com/composer/composer
- https://www.sonarsource.com/blog/securing-developer-tools-package-managers
- https://www.tenable.com/security/tns-2022-09
- CVSS vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:H/I:L/A:N- Weakness (CWE)
CWE-77- Platform
- Composer
- Package
composer/composer- Disclosed
- 05.10.2021
- Updated
- 11.10.2026 10:22
Sources and licenses
OSV / GitHub Advisory Database - GHSA-frqg-7g38-6gcf - CC BY 4.0
Vulnerability history: composer/composer
All published vulnerabilities of this package (Composer package), newest first. Shows whether this is a one-off slip or a package that needs watching.
- Total entries
- 17
- First → latest
- 04.2021 10.2026
- Without a fix
- 0
- Exploited in attacks
- 0
Severity breakdown
- High 13
- Medium 3
- Low 1
Disclosures per year
- 2021: 2
- 2022: 1
- 2023: 2
- 2024: 3
- 2025: 1
- 2026: 8
-
Improper escaping of command arguments on Windows leading to command injection this entry
Know which vulnerabilities affect your application
With the DockRay integration and software inventory enabled, DockRay checks reported component versions against known vulnerabilities and notifies you about confirmed matches. Coverage depends on the supported technology and available advisory data.