@google/gemini-cli@0.0.89999999999

Gemini CLI

  • latest version

    0.57.0

  • latest non vulnerable version

  • first published

    1 years ago

  • latest version published

    4 days ago

  • licenses detected

  • Direct Vulnerabilities

    Known vulnerabilities in the @google/gemini-cli package. This does not include vulnerabilities belonging to this package’s dependencies.

    Fix vulnerabilities automatically

    Snyk's AI Trust Platform automatically finds the best upgrade path and integrates with your development workflows. Secure your code at zero cost.

    Fix for free
    VulnerabilityVulnerable Version
    • C
    Command Injection

    @google/gemini-cli is a Gemini CLI

    Affected versions of this package are vulnerable to Command Injection via the processing of untrusted workspace folders in headless mode and the handling of tool allowlisting under --yolo mode. An attacker can execute arbitrary code by submitting malicious content or environment variables in untrusted directories or by exploiting insufficiently restricted shell command execution.

    How to fix Command Injection?

    Upgrade @google/gemini-cli to version 0.39.1, 0.40.0-preview.3 or higher.

    <0.39.1>=0.40.0-preview.2 <0.40.0-preview.3
    • H
    Improper Neutralization of Input Used for LLM Prompting

    @google/gemini-cli is a Gemini CLI

    Affected versions of this package are vulnerable to Improper Neutralization of Input Used for LLM Prompting due to an improper implementation of the getCommandRoot() and isCommandAllowed() functions. An attacker can inject malicious commands by leveraging command chaining (e.g., using &&) and contextual instructions embedded within arbitrary files (e.g., README.md), bypassing the tool's security checks. This can lead to the silent execution of arbitrary code when a user runs the tool on an untrusted repository, resulting in potential credential theft and system compromise.

    Notes:

    • In response to the disclosure, Google highlighted that Gemini CLI is offering sandboxing options via pre-built containers; Google also emphasized the existence of persistent warnings shown to users who don't have the feature enabled.

    • The researchers who discovered the vulnerability acknowledged this but noted that this less-secure, non-sandboxed mode is the default setting.

    • Users are recommended to use sandboxing mode when utilizing AI agents whenever possible.

    How to fix Improper Neutralization of Input Used for LLM Prompting?

    Upgrade @google/gemini-cli to version 0.1.14 or higher.

    <0.1.14