Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessReach exposed Ollama /api/pull endpoint
-
DeliverySend pull request with path-traversal layer digest
-
ExploitdigestToPath writes binary to /usr/lib/ollama
-
ExecutionWait for server/container restart
-
ImpactPlanted binary loaded and executed as root
Vulnerability Assessment
| Weakness |
CWE
OWASP Top 10:2025
A01:2025 - Broken Access Control
ASVS 5.0
V5 - File Handling Relative path traversal prevention
|
| Exploitation Conditions | The arbitrary-file-write primitive requires only network reachability to the Ollama HTTP API |
| Impact | This is a genuine high-priority vulnerability, not a high-CVSS-but-low-real-risk case, though the exploitation signals are more nuanced than the 9.4 score suggests. The vendor CVSS 4.0 vector (AV:N/AC:L/PR:N/UI:P) describes network-reachable, low-complexity, unauthenticated access, and the description confirms an unauthenticated remote attacker can trigger arbitrary file write via the |
| Exploit ScenarioDerived | An attacker with network access to an exposed Ollama instance (commonly a Docker container) sends a crafted |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Oct 08, 2026
Unauthenticated path traversal in the Ollama /api/pull endpoint lets a remote attacker write an arbitrary file outside the model store by submitting a crafted path-traversal sequence in the layer digest field, because the digestToPath function does not adequately validate digests before constructing a filesystem path. When the Ollama process can write to /usr/lib/ollama (described as the default in most Ollama Docker images) and the server or container is subsequently restarted, the planted binary is loaded and executed, yielding remote code execution as root; the same file-write primitive is available without authentication to anyone who can reach the API. The issue is fixed in Ollama 0.35.0, no public exploit code has been identified at time of analysis, CISA's SSVC assessment records exploitation as 'none', and no EPSS score was supplied in the source data. Real-world risk is high but conditional: exploitation of the full RCE chain depends on write access to /usr/lib/ollama and a restart, so deployments not using the default Docker image, running Ollama as a non-privileged user without write access to that directory, or not exposing the API to untrusted networks face substantially reduced exposure.
RemediationAI
Upgrade to Ollama 0.35.0 or later, which is the exact fixed version reported in the source data (vendor patch available; advisory: https://cert.pl/en/posts/2026/10/CVE-2026-103663/, vendor site https://ollama.com/). Because the file-write primitive works unauthenticated, prioritise the upgrade anywhere the API is exposed beyond localhost. If immediate patching is not possible, apply compensating controls that target the two escalation prerequisites: run the Ollama process as a dedicated non-privileged user (and remove any group/world write permission on /usr/lib/ollama or mount the installation directory read-only in the container), which blocks the write-to-execute step at the cost of breaking self-updating or in-place asset writes; and avoid exposing /api/pull to untrusted networks by binding the service to localhost or an internal interface and fronting it with authentication and network ACLs, accepting that this reduces but does not eliminate the path-traversal write for callers who retain API access. In containerised deployments, users running non-default or hardened images that never grant the container write access to /usr/lib/ollama are already outside the primary RCE path, but they should still treat the arbitrary-file-write primitive as a real risk and restrict restart-triggered file loading until 0.35.0 is deployed.
Affected VersionsENISA
Affected Packages
Source: OSV (Open Source Vulnerabilities)
Affects your stack
Affects 1 package in euvd
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
The vulnerability is a relative path traversal (CWE-23) in Ollama's model-pull workflow. Ollama exposes an HTTP API, and the /api/pull endpoint accepts a model reference whose layers are identified by digests; the internal digestToPath helper converts each digest into a filesystem path beneath the model store without sufficient normalization or validation of traversal sequences. An attacker who can reach the endpoint can therefore substitute a digest value containing something like ../ segments so that the resolved path escapes the model store and lands in an attacker-chosen location - with the server's privileges. Because Ollama is written to load and execute binaries from its installation directory on startup, planting a malicious file into /usr/lib/ollama converts the traversal write into persistent code execution on the next restart. The CPE cpe:2.3:a:ollama:ollama:*:*:*:*:*:*:*:* uses a wildcard version, so the authoritative affected range comes from EUVD, which records Ollama versions from 0.34.2 up to but not including 0.35.0. The supplied CVSS v4.0 vector (9.4) and the independent re-assessment (CVSS 3.1, AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:H/A:H) both treat the primitive as unauthenticated and network-reachable (PR:N), with scope change reflecting that the write escapes the model store into the host filesystem.
Know when Ollama 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:N/PR:N/UI:P/VC:H/VI:H/VA:H/SC:H/SI:H/SA:H
Unauthenticated network path-traversal write (AV:N/AC:L/PR:N/UI:N); scope change to host OS (S:C) and full C/I/A as root RCE results, with restart dependency noted as a conditional limiter rather than reflected as AC:H.
Primary rating from Vendor (CERT-PL).
CVSS VectorVendor: CERT-PL
Lifecycle Timeline
4DescriptionCVE.org
Ollama is vulnerable to path traversal in the /api/pull endpoint due to insufficient validation of layer digests by the digestToPath function. An unauthenticated remote attacker can specify a path traversal sequence as a layer digest, causing a malicious binary to be written outside the model store.
Critically if the server process has write access to /usr/lib/ollama (the default in most Ollama Docker images), an attacker can write the malicious file to that directory. On the next server restart, the file is loaded and executed, resulting in remote code execution as root.
This issue was fixed in version 0.35.0.
Articles & Coverage 1
Executive ViewAI
A critical flaw in Ollama, the self-hosted platform teams use to run large language models, allows an attacker who can reach its API to write files outside the intended model store and, in common Docker deployments, plant a binary that executes with root privileges after the next restart. The practical consequence is full compromise of the host or container running Ollama, which is typically placed near sensitive internal systems and model data. Leadership should care because these deployments are frequently internet- or partner-reachable and often lack the isolation and monitoring applied to other production tiers.
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
Path traversal exploits occur when applications use user-controlled input to construct file system paths without proper validation.
Remote Code Execution represents the critical moment when an attacker successfully runs arbitrary code on a target system without physical access.
Ollama before 0.1.34 does not validate the format of the digest (sha256 with 64 hex digits) when getting the model path,
Remote code execution in Ollama for Windows (versions 0.12.10 through 0.17.5) lets an attacker who can influence HTTP up
Silent auto-update code execution in Ollama for Windows (versions 0.12.10 through 0.17.5) stems from an update-verificat
Denial of service in Ollama's multi-modal image processing (versions 0.11.5-rc0 through 0.13.5) lets remote attackers cr
An issue was discovered in Ollama before 0.1.46. Rated high severity (CVSS 8.2), this vulnerability is remotely exploita
A vulnerability in the Ollama server version 0.5.11 allows a malicious user to cause a Denial of Service (DoS) attack by
A vulnerability in ollama/ollama versions <=0.3.14 allows a malicious user to upload and create a customized GGUF model
An issue in ollama v.0.12.10 allows a remote attacker to cause a denial of service via the fs/ggml/gguf.go, function rea
An issue in ollama v.0.12.10 allows a remote attacker to cause a denial of service via the GGUF decoder [CVSS 7.5 HIGH]
A divide by zero vulnerability exists in ollama/ollama version v0.3.3. Rated high severity (CVSS 7.5), this vulnerabilit
A vulnerability in ollama/ollama versions <=0.3.14 allows a malicious user to create a customized GGUF model file that,
A vulnerability in Ollama versions <=0.3.14 allows a malicious user to create a customized gguf model file that can be u
EUVD-2026-94962
GHSA-w8p2-phwr-px3r
NVD
CVE.org
EPSS
Vulnrichment
Exploit-DB