# CVE-2025-71439: llama.cpp heap out-of-bounds read in tokenizer loading

Source: https://junglewise.ai/threats/cve-2025-71439-llama-cpp-before-b5649-contains-a-heap-out-of-bounds-read  
Publisher: Junglewise Threat Intelligence, https://junglewise.ai/threats  
Published: 2026-10-27. Updated: 2026-10-27  
License: CC BY 4.0 with a link back

CVE-2025-71439 · Severity: medium · CVSS 5.5 · Published 2026-10-27

llama.cpp is a C++ implementation of the Llama language model that powers AI inference applications. A crafted GGUF model file with oversized token IDs can trigger an out-of-bounds memory read when loading the tokenizer, crashing the llama-cli or llama-server applications that process the model.

Technologies: [Ggml-Org Llama.Cpp](https://junglewise.ai/threats/technologies/ggml-org-llama-cpp). Vendors: [Ggml-Org](https://junglewise.ai/threats/vendors/ggml-org).

## Quick answers

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

**How severe is CVE-2025-71439?** Medium severity, with a CVSS score of 5.5, published 27 October 2026.

**Which products and versions are affected?** Ggml-Org Llama.Cpp before b5649.

**Is there a fix for CVE-2025-71439?** Yes: fixed in b5649. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.

**How is CVE-2025-71439 attacked?** It is attacked with local access, in a software library.

**Am I affected by CVE-2025-71439?** Check whether you run Ggml-Org Llama.Cpp 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.

## How to fix

- Fixed in b5649

## Technical details

A heap out-of-bounds read vulnerability exists in the llama_vocab::impl::print_info() function when processing GGUF model files. An attacker can supply a crafted model with a short tokenizer.ggml.tokens array but large special token IDs, causing the code to read past the id_to_token buffer boundary. This results in a crash (denial of service) during model loading in llama-cli or llama-server.

## Affected products

- ggml-org llama.cpp before b5649

## Timeline

- 2026-10-27: disclosed

## References

- [https://github.com/ggml-org/llama.cpp/blob/b5648/src/llama-vocab.cpp](https://github.com/ggml-org/llama.cpp/blob/b5648/src/llama-vocab.cpp)
- [https://github.com/ggml-org/llama.cpp/commit/c33fe8b8c4427202706b1434e9fc8ab5752c9cac](https://github.com/ggml-org/llama.cpp/commit/c33fe8b8c4427202706b1434e9fc8ab5752c9cac)

## Related threats

- [llama.cpp ggml-rpc server denial of service](https://junglewise.ai/threats/cve-2026-119052-llama-cpp-b2877-before-b11935-contains-an-uncaught-exception)
- [llama.cpp out-of-bounds write in ggml-rpc RDMA transport](https://junglewise.ai/threats/cve-2026-118375-llama-cpp-b8841-before-b11865-contains-an-out-of-bounds-write)
- [llama.cpp integer overflow in gguf_init_from_reader](https://junglewise.ai/threats/cve-2026-116829-llama-cpp-b10398-before-b11301-contains-an-integer-overflow)
- [llama.cpp heap out-of-bounds write in PLAMO2 tokenizer](https://junglewise.ai/threats/cve-2026-116816-llama-cpp-b5899-before-b10261-contains-a-heap-out-of-bounds)
- [llama.cpp out-of-bounds read in decode/encode functions](https://junglewise.ai/threats/cve-2024-58400-llama-cpp-before-b3701-contains-an-out-of-bounds-read)
