Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessSubmit malicious PR/issue to CI repo
-
DeliveryPlant untrusted .env overriding GEMINI_CLI_HOME
-
ExploitHeadless Gemini CLI auto-trusts workspace
-
ExecutionLoads attacker config / bypasses allowlist
-
ImpactExecute arbitrary code on runner
Vulnerability Assessment
| Weakness |
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V2 - Validation and Business Logic Input validation, allowlisting
|
| Exploitation Conditions | Requires Gemini CLI (or the run-gemini-cli Action) running in headless/non-interactive mode over folder contents the attacker can influence - specifically CI/CD workflows that process untrusted input such as externally submitted pull requests or issues. Exploitation of the primary vector needs the attacker to place a malicious local .env / .gemini configuration file in the reviewed workspace that overrides GEMINI_CLI_HOME; the alternate --yolo vector requires the CLI to be run with --yolo and a tool allowlist permitting run_shell_command, then abused via prompt injection. Limiting factors: this affects only headless deployments with the pre-patch automatic folder-trust behavior; interactive use and workflows that only process trusted internal content are not exposed, and the AC:H rating reflects this non-default, untrusted-automation prerequisite. |
| Impact | The vendor CVSS 4.0 base score is 9.2 (AV:N/AC:H/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H with low subsequent-system impact), reflecting unauthenticated, no-user-interaction remote code execution but elevated attack complexity - consistent with the requirement that the target run Gemini CLI in headless mode over untrusted folder contents (e.g., CI reviewing external PRs/issues). No EPSS score is provided, the CVE is not in CISA KEV, and no public POC is referenced, so this is a real-but-conditional priority rather than a mass-exploited threat: exposure is limited to organizations running Gemini CLI or the run-gemini-cli Action in automated pipelines that process untrusted contributions. The AC:H rating aligns with the description (needs the specific auto-trust headless behavior and attacker ability to place files in the reviewed workspace), so raw score notwithstanding, realistic risk concentrates on public-repo CI/CD automation. |
| Exploit ScenarioDerived | An attacker opens a pull request (or issue) against a public repository whose CI runs the run-gemini-cli GitHub Action in headless mode; the PR includes a malicious .env / .gemini config that overrides GEMINI_CLI_HOME (or exploits the --yolo allowlist bypass via prompt injection). When the workflow processes the untrusted contribution, Gemini CLI auto-trusts the workspace, loads the attacker's config, and executes arbitrary code on the CI runner. No authentication or user interaction is required, though the elevated attack complexity (AC:H) reflects the need for the vulnerable headless auto-trust configuration. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Sep 10, 2026
Arbitrary code execution in Google Cloud's Gemini CLI (npm @google/gemini-cli < 0.39.1) and the run-gemini-cli GitHub Action (< 0.1.22) lets an unprivileged attacker run code on the host by planting untrusted local .env / .gemini configuration files that override GEMINI_CLI_HOME. In headless (CI) mode, previous versions auto-trusted workspace folders and processed their config/environment variables, so a malicious pull request or issue processed by an automated Gemini workflow could trigger RCE; a related --yolo tool-allowlist bypass compounds the risk. Patched by vendor; no public exploit identified at time of analysis and it is not in CISA KEV.
RemediationAI
Upgrade to the vendor-released fixed versions: Gemini CLI (@google/gemini-cli) 0.39.1 (or 0.40.0-preview.3 for the preview channel) and the run-gemini-cli GitHub Action 0.1.22. After upgrading, note the breaking change: headless mode no longer auto-trusts workspace folders, so CI/CD workflows must explicitly configure folder trust for workspace-specific settings (.env, .gemini) to load, and any workflows that relied on --yolo ignoring the tool allowlist must update ~/.gemini/settings.json allowlists (overly broad entries like run_shell_command that permit arbitrary commands should be tightened to specific safe commands). As a compensating control until patched, avoid running Gemini CLI in headless mode over untrusted directory contents - do not run automated Gemini workflows against fork/external pull requests or user-submitted issues, and restrict which commands run_shell_command may execute; the trade-off is reduced automation coverage for untrusted contributions. See the advisory GHSA-wpqr-6v78-jr5g and the v0.1.22 release for guidance.
Affected VersionsENISA
Affected Packages
Source: OSV (Open Source Vulnerabilities)
Affects your stack
Affects 4 packages in npm, euvd
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
The affected components are Google's AI-assisted developer tooling: the Gemini CLI (cpe:2.3:a:google_cloud:gemini_cli) and the run-gemini-cli GitHub Action (cpe:2.3:a:google_cloud:run-gemini-cli_github_action). The root cause is CWE-20 (Improper Input Validation): in headless/non-interactive mode the CLI automatically treated workspace folders as trusted and loaded configuration and environment variables from files like .env and .gemini/settings.json without requiring explicit folder trust. Because these local files can override sensitive variables such as GEMINI_CLI_HOME, attacker-controlled workspace contents can redirect the CLI's home/config resolution and cause execution of attacker-influenced behavior. The GHSA advisory also documents a second hardening: under --yolo mode the CLI previously ignored the fine-grained tool allowlist in ~/.gemini/settings.json, so run_shell_command allowlists were not enforced, enabling RCE via prompt injection when processing untrusted input.
Know when Gemini Cli gets its next vulnerability
- Watch products and get an email when something new is published
- Check this CVE against your own stack and servers
- Exploit and PoC references, threat intelligence from 22 sources
No credit card · 7-day full trial
Severity by source
CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N/U:Amber
Unauthenticated attacker submits untrusted content processed by CI (AV:N/PR:N/UI:N), but requires the vulnerable headless auto-trust configuration (AC:H); full RCE on the runner gives C/I/A:H.
Primary rating from Vendor (GoogleCloud).
CVSS VectorVendor: GoogleCloud
Lifecycle Timeline
4DescriptionCVE.org
A vulnerability in the Gemini CLI and associated GitHub Action allowed an unprivileged attacker to achieve an arbitrary code execution in Gemini CLI via untrusted local .env files overriding GEMINI_CLI_HOME.
Technical POC Analysis
The vulnerable behavior is in Gemini CLI's headless trust handling.
Full technical POC analysis - root cause, step-by-step exploitation and patch breakdown - is part of the Pro and Business plans.
Executive ViewAI
Google's Gemini CLI tools (@google/gemini-cli npm package and run-gemini-cli GitHub Action) contain a critical remote code execution flaw in CI/CD automation. Attackers can exploit this by submitting malicious pull requests that inject untrusted configuration files, executing code with full build environment privileges and risking theft of credentials, source code, and deployment artifacts.
Apply vendor patch.
Threat Intelligence Overview
How this decision was reached
The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
Remote Code Execution represents the critical moment when an attacker successfully runs arbitrary code on a target system without physical access.
EUVD-2026-75326
GHSA-2255-3477-vp73
NVD
CVE.org
EPSS
Vulnrichment
Exploit-DB