OS Command Injection in git-pull-or-clone
The package git-pull-or-clone before 2.0.2 is vulnerable to Command Injection due to the use of the --upload-pack feature of git which is also supported for git clone. The source includes the use of the secure child process API spawn(). However, the outpath parameter passed to it may be a command-line argument to the git clone command and result in arbitrary command injection.
Credits
Credit @lirantal for discovering this vulnerability.
Affected software
Click a technology to see all vulnerabilities affecting it.
| Platform | Package | Vulnerable versions | Fixed in |
|---|---|---|---|
| npm package | git-pull-or-clone | < 2.0.2 | 2.0.2 |
References
- https://nvd.nist.gov/vuln/detail/CVE-2022-24437
- https://github.com/feross/git-pull-or-clone/commit/f9ce092be13cc32e685dfa26e7705e9c6e3108a3
- https://gist.github.com/lirantal/327e9dd32686991b5a1fa6341aac2e7b
- https://github.com/feross/git-pull-or-clone
- https://snyk.io/vuln/SNYK-JS-GITPULLORCLONE-2434307
- CVSS vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H- Weakness (CWE)
CWE-77, CWE-78- Platform
- npm
- Package
git-pull-or-clone- Disclosed
- 03.05.2022
- Updated
- 11.10.2026 10:22
Sources and licenses
OSV / GitHub Advisory Database - GHSA-3x62-x456-q2vm - CC BY 4.0
Vulnerability history: git-pull-or-clone
All published vulnerabilities of this package (npm package), newest first. Shows whether this is a one-off slip or a package that needs watching.
This is the only known vulnerability of this package.
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.