CVE-2025-0317: Ollama: DoS via malicious GGUF model file upload
HIGH PoC AVAILABLE CISA: TRACK*Any Ollama instance ≤0.3.14 with model upload access can be crashed by an unauthenticated attacker with a single crafted GGUF file — no credentials, no complexity. Upgrade to a version beyond 0.3.14 immediately and audit network exposure of your Ollama API endpoints. If patching is not feasible today, block the model creation endpoint at the network layer as an interim control.
Risk Assessment
High exploitability given the CVSS 7.5 profile: unauthenticated, network-reachable, low complexity. Organizations exposing Ollama for team-wide LLM access, internal portals, or developer tooling are directly at risk. Impact is scoped to availability — no data exfiltration or code execution path — but persistent crashes disrupt AI-dependent workflows, can trigger incident response costs, and may signal active reconnaissance of the AI stack.
Affected Systems
| Package | Ecosystem | Vulnerable Range | Patched |
|---|---|---|---|
| ollama | pip | — | No patch |
Do you use ollama? You're affected.
Severity & Risk
Attack Surface
Recommended Action
5 steps-
Upgrade Ollama to a version beyond 0.3.14 immediately — this is the primary fix.
-
If patching is delayed, block external access to the Ollama API (default port 11434) at the firewall or ingress layer.
-
Restrict the model creation/upload endpoint to authenticated, authorized users via a reverse proxy (nginx/Caddy with auth middleware).
-
Monitor Ollama process restarts as an indicator of exploitation attempts — unexpected crash loops warrant investigation.
-
Audit all publicly exposed Ollama instances using your asset inventory; check Shodan exposure for your IP ranges.
CISA SSVC Assessment
Source: CISA Vulnrichment (SSVC v2.0). Decision based on the CISA Coordinator decision tree.
Classification
Compliance Impact
This CVE is relevant to:
Frequently Asked Questions
What is CVE-2025-0317?
Any Ollama instance ≤0.3.14 with model upload access can be crashed by an unauthenticated attacker with a single crafted GGUF file — no credentials, no complexity. Upgrade to a version beyond 0.3.14 immediately and audit network exposure of your Ollama API endpoints. If patching is not feasible today, block the model creation endpoint at the network layer as an interim control.
Is CVE-2025-0317 actively exploited?
Proof-of-concept exploit code is publicly available for CVE-2025-0317, increasing the risk of exploitation.
How to fix CVE-2025-0317?
1. Upgrade Ollama to a version beyond 0.3.14 immediately — this is the primary fix. 2. If patching is delayed, block external access to the Ollama API (default port 11434) at the firewall or ingress layer. 3. Restrict the model creation/upload endpoint to authenticated, authorized users via a reverse proxy (nginx/Caddy with auth middleware). 4. Monitor Ollama process restarts as an indicator of exploitation attempts — unexpected crash loops warrant investigation. 5. Audit all publicly exposed Ollama instances using your asset inventory; check Shodan exposure for your IP ranges.
What systems are affected by CVE-2025-0317?
This vulnerability affects the following AI/ML architecture patterns: LLM inference servers, self-hosted AI platforms, local model serving, AI developer environments, internal AI assistants.
What is the CVSS score for CVE-2025-0317?
CVE-2025-0317 has a CVSS v3.1 base score of 7.5 (HIGH). The EPSS exploitation probability is 2.85%.
Technical Details
NVD Description
A vulnerability in ollama/ollama versions <=0.3.14 allows a malicious user to upload and create a customized GGUF model file on the Ollama server. This can lead to a division by zero error in the ggufPadding function, causing the server to crash and resulting in a Denial of Service (DoS) attack.
Exploitation Scenario
Attacker scans for Ollama instances on port 11434 (Shodan has thousands indexed) or enumerates an internal corporate network. They craft a GGUF model file with malformed padding parameters — a single arithmetic error in the ggufPadding function triggers a division by zero. With one unauthenticated POST to the Ollama model creation API, the server process crashes. Since no authentication is required and the crash is deterministic, the attacker can loop this after every restart, achieving persistent denial of the AI inference service with minimal tooling.
Weaknesses (CWE)
CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H References
- huntr.com/bounties/a9951bca-9bd8-49b2-b143-4cd4219f9fa0 Exploit 3rd Party
Timeline
Related Vulnerabilities
CVE-2025-63389 9.8 ollama: Missing Auth allows unauthenticated access
Same package: ollama CVE-2026-7482 9.1 Ollama: heap OOB read leaks API keys and chat data
Same package: ollama CVE-2026-44007 9.1 vm2: sandbox escape via nesting:true enables RCE
Same package: ollama CVE-2024-37032 8.8 Ollama: path traversal enables RCE via model blob API
Same package: ollama CVE-2024-39720 8.2 Ollama: OOB read in GGUF parser enables remote DoS
Same package: ollama
AI Threat Alert