Intel

AIKIDO-2026-10023

@google/gemini-cli-core is vulnerable to Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection')

Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection') Pre-CVE
Found by Aikido Intel before public disclosure or CVE publication.
Published Jan 12, 2026

52

Medium Risk

This Affects:

JS@google/gemini-cli-core
0.15.0 - 0.22.5
Fixed in 0.23.0
Are you affected? Scan for Free

TL;DR

Affected versions of this package contain a command injection vulnerability in the hooks system where unsanitized expansion of the $GEMINI_PROJECT_DIR and $CLAUDE_PROJECT_DIR variables occurred immediately before shell execution, allowing an attacker who controls a malicious directory path name to inject arbitrary commands by crafting environment variables or pathnames containing shell metacharacters, leading to arbitrary code execution with the privileges of the application.

Who does this affect?

You are affected if you are using a version that falls within the vulnerable range.

Background info

@google/gemini-cli-core is vulnerable to Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection') in versions 0.15.0 - 0.22.5.

How to fix this

Upgrade the @google/gemini-cli-core library to the patch version.