Description
Ollama versions 0.14.0 before 0.31.2 contain an incorrect authorization vulnerability in the experimental agent mode Bash tool approval mechanism that fails to properly parse shell syntax. Attackers who can influence model output through prompt injection can execute additional shell commands by appending control operators like semicolons or logical operators to approved commands, bypassing the session approval requirement.
Published: 2026-09-29
Score: 8.5 High
EPSS: < 1% Very Low
KEV: No
Impact: Command Execution via Authorization Bypass
Action: Immediate Patch
AI Analysis

Impact

Ollama versions 0.14.0 through 0.31.1 contain a flaw in the experimental agent Bash tool where the approval logic incorrectly parses shell syntax. When an attacker can influence model output, for example through prompt injection, they can append control operators such as semicolons or logical operators to an approved command, causing the shell to execute unintended commands. This bypasses the intended session approval requirement and permits arbitrary command execution within the agent context, exposing the host to confidentiality, integrity, and availability risks.

Affected Systems

Ollama’s Ollama application, specifically the experimental agent Bash component, is affected from release 0.14.0 up to and including 0.31.1. All users running those releases with experimental agent mode enabled are at risk.

Risk and Exploitability

The vulnerability scores a CVSS of 8.5, indicating high severity. EPSS data is not available, and it is not currently listed in CISA’s KEV catalog, but the high CVSS coupled with the ability to inject commands via prompt manipulation makes it a serious threat. The likely attack vector is remote via prompt injection when the application is exposed to untrusted input, as the attacker can influence model output to append control operators. Once the privilege bypass is achieved, the attacker can execute arbitrary shell commands, potentially compromising the host.

Generated by OpenCVE AI on September 30, 2026 at 01:00 UTC.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Upgrade to Ollama version 0.31.2 or later, which fixes the approval parsing bug.
  • Disable the experimental agent mode or ensure that only trusted users can invoke it.
  • Restrict network access to the Ollama daemon to trusted hosts and filter all prompt inputs for injection patterns.
  • Monitor system logs for unexpected shell command executions and unauthorized approval attempts.

Generated by OpenCVE AI on September 30, 2026 at 01:00 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories yet.

History

Tue, 29 Sep 2026 18:30:00 +0000

Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'none', 'Technical Impact': 'total'}, 'version': '2.0.3'}


Tue, 29 Sep 2026 17:00:00 +0000

Type Values Removed Values Added
Description Ollama versions 0.14.0 before 0.31.2 contain an incorrect authorization vulnerability in the experimental agent mode Bash tool approval mechanism that fails to properly parse shell syntax. Attackers who can influence model output through prompt injection can execute additional shell commands by appending control operators like semicolons or logical operators to approved commands, bypassing the session approval requirement.
Title Ollama 0.14.0 before 0.31.2 Experimental Agent Bash Approval Bypass via Prefix-Based Authorization
First Time appeared Ollama
Ollama ollama
Weaknesses CWE-863
CPEs cpe:2.3:a:ollama:ollama:*:*:*:*:*:*:*:*
Vendors & Products Ollama
Ollama ollama
References
Metrics cvssV3_1

{'score': 7.8, 'vector': 'CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H'}

cvssV4_0

{'score': 8.5, 'vector': 'CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N'}


cve-icon MITRE

Status: PUBLISHED

Assigner: VulnCheck

Published:

Updated: 2026-09-29T17:28:26.473Z

Reserved: 2026-09-29T16:10:48.654Z

Link: CVE-2026-102697

cve-icon Vulnrichment

Updated: 2026-09-29T17:28:21.269Z

cve-icon NVD

Status : Awaiting Analysis

Published: 2026-09-29T17:17:08.150

Modified: 2026-09-29T21:32:59.833

Link: CVE-2026-102697

cve-icon Redhat

No data.

cve-icon OpenCVE Enrichment

Updated: 2026-09-30T02:30:17Z

Weaknesses