CVE-2022-24437: OS Command Injection in git-pull-or-clone

git-pull-or-clone Updated 02 Oct 2025

Summary

03/05/2022
Yes i
Critical
9.8

CVE-2022-24437: OS Command Injection in git-pull-or-clone. Affects git-pull-or-clone versions < 2.0.2. Fixed in 2.0.2. How to fix ↓

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored MarkAI Find prospects already talking about the problem you solve AI watches the communities your customers use to find qualified prospects, then alerts you when a conversation is worth joining. See MarkAI

Background

The git-pull-or-clone package is an npm package that provides functionality for pulling or cloning Git repositories. It utilizes the --upload-pack feature of git, which is also supported for git clone operations. The package uses the secure child process API spawn() for executing commands. However, a vulnerability exists in versions prior to 2.0.2, where the outpath parameter passed to spawn() can be manipulated to inject arbitrary commands into the git clone command.

Vulnerability Detail

The vulnerability in git-pull-or-clone allows for OS command injection. By manipulating the outpath parameter, an attacker can inject arbitrary commands into the git clone command. This can lead to various security risks, including remote code execution, unauthorized access to sensitive information, and potential compromise of the host system. The vulnerability has a CVSS score of 9.8, indicating its critical severity.

How To Fix

Latest published version: 2.0.2 as of 23 Oct 2026

npm install git-pull-or-clone@2.0.2

The newest release already contains this fix.

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Workaround

There is no known workaround for this vulnerability. It is crucial to update the package to the fixed version to mitigate the risk of OS command injection.

Conclusion

The OS command injection vulnerability in git-pull-or-clone can have severe consequences, including remote code execution and unauthorized access. It is crucial to update the package to version 2.0.2 or later to mitigate this vulnerability. For further support on vulnerability remediation, you can contact DevNack.com.

See every vulnerability recorded for git-pull-or-clone →

Share this vulnerability

FAQ

The vulnerability allows for OS command injection, which can lead to remote code execution, unauthorized access to sensitive information, and potential compromise of the host system.

You can use Vulert's playground at Vulert Scanner to check if your application is affected by this vulnerability. Vulert monitors and alerts in real-time for open-source vulnerabilities using package-lock.json.

Yes, updating the git-pull-or-clone package to version 2.0.2 or later fixes this vulnerability. It is recommended to update the package as soon as possible.

No, there are no known workarounds for this vulnerability. Updating the package to the fixed version is the recommended solution.

This vulnerability was discovered by @lirantal and reported to the package maintainers.

How To Fix

Latest published version: 2.0.2 as of 23 Oct 2026

npm install git-pull-or-clone@2.0.2

The newest release already contains this fix.

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback