OS Command Injection Affecting gemini-cli package, versions <0.49.0-r3


Severity

Recommended
low

Based on default assessment until relevant scores are available.

Threat Intelligence

Social Trends
EPSS
0.65% (47th percentile)

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications
  • Snyk IDSNYK-CHAINGUARDLATEST-GEMINICLI-17872365
  • published7 Jul 2026
  • disclosed13 Apr 2026

Introduced: 13 Apr 2026

CVE-2026-28291  (opens in a new tab)
CWE-78  (opens in a new tab)

How to fix?

Upgrade Chainguard gemini-cli to version 0.49.0-r3 or higher.

NVD Description

Note: Versions mentioned in the description apply only to the upstream gemini-cli package and not the gemini-cli package as distributed by Chainguard. See How to fix? for Chainguard relevant fixed versions and status.

simple-git enables running native Git commands from JavaScript. Versions up to and including 3.31.1 allow execution of arbitrary commands through Git option manipulation, bypassing safety checks meant to block dangerous options like -u and --upload-pack. The flaw stems from an incomplete fix for CVE-2022-25860, as Git's flexible option parsing allows numerous character combinations (e.g., -vu, -4u, -nu) to circumvent the regular-expression-based blocklist in the unsafe operations plugin. Due to the virtually infinite number of valid option variants that Git accepts, a complete blocklist-based mitigation may be infeasible without fully emulating Git's option parsing behavior. This issue has been fixed in version 3.32.0.

CVSS Base Scores

version 3.1