CVE-2025-44779
📋 TL;DR
This vulnerability in Ollama v0.1.33 allows attackers to delete arbitrary files by sending a specially crafted packet to the /api/pull endpoint. It affects systems running vulnerable versions of Ollama with the API exposed. The issue stems from improper input validation (CWE-20) in the file handling mechanism.
💻 Affected Systems
- Ollama
📦 What is this software?
Ollama by Ollama
⚠️ Risk & Real-World Impact
Worst Case
Complete system compromise through deletion of critical system files, configuration files, or user data, potentially leading to service disruption, data loss, or privilege escalation.
Likely Case
Targeted deletion of application files, configuration files, or user data causing service disruption or data loss in Ollama deployments.
If Mitigated
Limited impact if proper network segmentation and access controls prevent unauthorized access to the Ollama API endpoint.
🎯 Exploit Status
Exploitation requires crafting specific packets to the /api/pull endpoint. No public proof-of-concept code is available at this time.
🛠️ Fix & Mitigation
✅ Official Fix
Patch Version: v0.1.34 or later
Vendor Advisory: https://github.com/ollama/ollama
Restart Required: No
Instructions:
1. Stop the Ollama service. 2. Update Ollama to version v0.1.34 or later using your package manager or by downloading from the official repository. 3. Restart the Ollama service.
🔧 Temporary Workarounds
Network Access Restriction
allRestrict network access to the Ollama API endpoint to only trusted IP addresses or networks.
Use firewall rules to block access to port 11434 (default Ollama port) from untrusted networks
API Endpoint Disablement
allDisable the vulnerable /api/pull endpoint if not required for your use case.
Configure Ollama to disable the API or restrict endpoint access through application configuration
🧯 If You Can't Patch
- Implement strict network segmentation to isolate Ollama instances from untrusted networks
- Deploy web application firewall (WAF) rules to block malicious requests to the /api/pull endpoint
🔍 How to Verify
Check if Vulnerable:
Check if Ollama version is v0.1.33 by examining the service version or installation package.
Check Version:
ollama --version
Verify Fix Applied:
Verify Ollama version is v0.1.34 or later after applying the update.
📡 Detection & Monitoring
Log Indicators:
- Unusual requests to /api/pull endpoint with crafted parameters
- File deletion events in system logs originating from Ollama process
Network Indicators:
- Unusual traffic patterns to Ollama API port 11434
- Multiple DELETE or POST requests to /api/pull endpoint from single source
SIEM Query:
source="ollama.log" AND (uri_path="/api/pull" AND (method="POST" OR method="DELETE"))