llama.cpp before b3701 contains an out-of-bounds read vulnerability in llama_decode_internal and llama_encode_internal
Source GCVE Database
Not known to be exploited · CVSS 8.8 High : upgrade to b3701 soon.
Data as of 27 Oct 2026, 04:16 UTC
- Patch
- Available – fixed in b3701
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:L/VI:N/VA:H/SC:N/SI:N/SA:NExploitation evidence
Disclosed: evidence found.
CVE published 27 Oct 2026
Detectable: no evidence on record.
No public nuclei template indexed
Weaponised: no evidence on record.
No public exploit code indexed in Metasploit or Exploit-DB
Exploited in the wildExploited: no evidence on record.
Not in CISA KEV and no source reports exploitation
Observed by OffSeq MirageSeen by Mirage: no evidence on record.
No attack traffic recorded by OffSeq Mirage sensors
A missing step is not evidence of safety. Sources: cve.org (opens in a new tab), the Metasploit, Exploit-DB and nuclei-templates index as of 26 Oct 2026.
What to do
Upgrade llama.cpp to b3701.
Affected software
| Product | Affected | Fixed in |
|---|---|---|
| ggml-orgllama.cpp | Affected
| Fixed in
|
GitHubllama.cpppkg:github/llama.cppOther threats | Affected
| Fixed in
|
Check your own hosts for these packages with threat-finder (opens in a new tab), our free open-source scanner.
AI-suggested
A fix is available in llama.cpp at or after commit b3701. Users should update to this version or later to remediate the vulnerability. No vendor advisory or patch link is provided, so confirm the fix by reviewing the project's commit history or official channels.
Description
An out-of-bounds read vulnerability exists in llama.cpp versions before commit b3701 in the functions llama_decode_internal and llama_encode_internal. This flaw allows remote unauthenticated attackers to read memory or crash the process by sending crafted integer-array prompts with token IDs outside the valid range to the llama-server /completion endpoint.
References
- nvd.nist.gov/vuln/detail/CVE-2024-58400 (opens in a new tab)
- github.com/ggml-org/llama.cpp/pull/9359 (opens in a new tab)
- github.com/ggml-org/llama.cpp/commit/eae597182cb61bbde0b26e7cec5999d28b9327fe (opens in a new tab)
- github.com/ggml-org/llama.cpp/commit/faf69d4237c9ae4d7f572b4674d1002463e8acd3 (opens in a new tab)
- github.com/ggml-org/llama.cpp/blob/b3681/examples/server/server.cpp (opens in a new tab)
- github.com/ggml-org/llama.cpp/releases/tag/b3701 (opens in a new tab)
- vulncheck.com/advisories/llama-cpp-before-b3701-out-of-bounds-read-in-llama-decode-via-token-ids (opens in a new tab)