# CVE-2026-86289: Ollama integer overflow in GGUF decoder

Source: https://junglewise.ai/threats/cve-2026-86289-ollama-integer-overflow-in-gguf-decoder  
Publisher: Junglewise Threat Intelligence, https://junglewise.ai/threats  
Published: 2026-09-07. Updated: 2026-09-26  
License: CC BY 4.0 with a link back

CVE-2026-86289 · Severity: medium · CVSS 4.3 · Published 2026-09-07

Ollama is an open-source framework for running large language models locally. A flaw in its GGUF file format decoder can cause integer overflow when processing specially crafted model files, potentially leading to memory corruption or denial of service when loading untrusted models.

Technologies: [Ollama](https://junglewise.ai/threats/technologies/ollama). Vendors: [Ollama](https://junglewise.ai/threats/vendors/ollama).

## Quick answers

**Is CVE-2026-86289 exploited in the wild?** No. Junglewise Threat Intelligence has no report of CVE-2026-86289 being exploited in the wild.

**How severe is CVE-2026-86289?** Medium severity, with a CVSS score of 4.3, published 7 September 2026.

**Which products and versions are affected?** Ollama up to 0.31.1.

**Is there a fix for CVE-2026-86289?** A patch was published on 2026-07-06: Fix available in version 0.31.2-rc1 (commit 67b6a1c2d45321e0cb3c04a18073f9818de7724b) Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.

**How is CVE-2026-86289 attacked?** It is attacked over the network, in a software library.

**Am I affected by CVE-2026-86289?** Check whether you run Ollama at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

## Technical details

An integer overflow vulnerability exists in the readGGUFV1String function within the GGUF decoder component (fs/ggml/gguf.go). The vulnerability occurs due to improper bounds checking during parsing of GGUF file format structures. An attacker can craft a malicious GGUF model file with specially crafted size fields to trigger integer overflow during tensor element count calculation. The attack is remotely exploitable if Ollama is exposed to untrusted file sources (e.g., model download endpoints). The vulnerability has been patched in version 0.31.2-rc1 with commit 67b6a1c, which implements proper overflow detection by checking if multiplication of tensor dimensions would overflow before performing the calculation.

## Affected products

- Ollama Ollama up to 0.31.1

## Timeline

- 2026-09-07: disclosed
- 2026-07-06: patched: Fix available in version 0.31.2-rc1 (commit 67b6a1c2d45321e0cb3c04a18073f9818de7724b)

## References

- [https://github.com/ollama/ollama/](https://github.com/ollama/ollama/)
- [https://github.com/ollama/ollama/commit/67b6a1c2d45321e0cb3c04a18073f9818de7724b](https://github.com/ollama/ollama/commit/67b6a1c2d45321e0cb3c04a18073f9818de7724b)

## Related threats

- [Ollama server-side request forgery in Pull API](https://junglewise.ai/threats/cve-2026-108836-a-vulnerability-has-been-found-in-ollama-up-to-0-34-1-the)
- [Ollama authorization bypass in experimental agent Bash tool approval](https://junglewise.ai/threats/cve-2026-102697-ollama-versions-0-14-0-before-0-31-2-contain-an-incorrect)
- [Ollama unvalidated redirect in model blob downloads](https://junglewise.ai/threats/cve-2026-85180-ollama-unvalidated-redirect-in-model-blob-downloads)
- [Ollama uncontrolled memory allocation in GGUF metadata parser](https://junglewise.ai/threats/cve-2026-65315-ollama-uncontrolled-memory-allocation-in-gguf-metadata-parser)
- [Ollama downloadBlob improper validation of array index denial of service](https://junglewise.ai/threats/cve-2026-15685-ollama-downloadblob-improper-validation-of-array-index-denial-of)
