CVE-2022-24440 is a high-severity (CVSS 8.1) CWE-88 vulnerability in cocoapods-downloader. A fix is available for cocoapods-downloader — see the affected versions and patch details below.
Command Injection
EPSS Exploitation Probability
Probability of exploitation in the next 30 days, from FIRST.org EPSS.
How urgent is this, really
Where this sits among everything scored
Real-World Exposure
cocoapods-downloader💎cocoapods-downloaderReal-time download stats are indexed for npm and PyPI packages. This vulnerability affects RubyGems packages — download data is not available via public APIs for these ecosystems.
Description
The package cocoapods-downloader before 1.6.0, from 1.6.2 and before 1.6.3 are vulnerable to Command Injection via git argument injection. When calling the Pod::Downloader.preprocess_options function and using git, both the git and branch parameters are passed to the git ls-remote subcommand in a way that additional flags can be set. The additional flags can be used to perform a command injection.
Affected Packages
| Ecosystem | Package | Vulnerable range | Fix |
|---|---|---|---|
| 💎RubyGems | cocoapods-downloader | all versions | 1.6.0bundle update cocoapods-downloader --conservative |
| 💎RubyGems | cocoapods-downloader | ≥ 1.6.2&&< 1.6.3 | 1.6.3bundle update cocoapods-downloader --conservative |
Affected Products
cocoapods-downloadercocoapodsDetection & mitigation playbook
Open-source dependencyDetect
Scan your dependency tree (package-lock.json, pnpm-lock.yaml, requirements.txt, go.sum, etc.) for cocoapods-downloader, including transitive dependencies — a direct dependency you never call can still pull in a vulnerable version.
Fix
Update cocoapods-downloader to 1.6.0 or later, then make sure no transitive (indirect) dependency still pins the vulnerable range — O3 confirms CVE-2022-24440 is resolved across your whole dependency graph.
Workarounds
Stop passing untrusted input into the interpreter or shell: call the affected binary with an argument array rather than a composed command string, reject anything outside a strict allowlist of expected values, and run the component under an account that cannot reach beyond the work it legitimately does.
Frequently Asked Questions
Is CVE-2022-24440 in your dependencies?
Find it across RubyGems, including transitive dependencies.