Browse / Unsafe Model Loading and Supply Chain / CVE-2025-0317
Ollama Divide By Zero vulnerability
- Class
- Unsafe Model Loading and Supply Chain (filed by a model that read the advisory)
- Technique
- Denial of service
- Affected
- github.com/ollama/ollama (Go)
- CVSS
- CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
- EPSS
- 14.5% chance of exploitation in 30 days
How it works, in short
A crafted GGUF model file uploaded to Ollama triggers a division by zero in the padding routine, crashing the server. (Our summary, written by a model. The source text is below.)
Details
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.
References
- https://nvd.nist.gov/vuln/detail/CVE-2025-0317
- https://github.com/ollama/ollama
- https://huntr.com/bounties/a9951bca-9bd8-49b2-b143-4cd4219f9fa0
Source: GitHub Advisory Database, used under CC BY 4.0.