CVE-2026-116816

llama.cpp b5899 before b10261 Heap Out-of-Bounds Write via plamo2 Tokenizer

Published Oct 27, 2026 CVSS 4.0 · 8.5 High EPSS < 1% KEV · Not listed
Description
llama.cpp b5899 before b10261 contains a heap out-of-bounds write vulnerability in llm_tokenizer_plamo2::build that allows attackers to corrupt heap memory via crafted GGUF models. Attackers can supply BYTE-typed token text like <0x-1> whose negative parsed value writes token ids before the bytes_ buffer during model loading, causing crashes or potential code execution.

Analysis

AI-generated

Technical impact

A malformed token entry such as <0x-1> triggers a heap out‑of‑bounds write in the plamo2 tokenizer’s build routine. When a GGUF model is loaded, the parser interprets the negative value and writes token identifiers before the allocated byte buffer, corrupting heap memory. This overflow can cause the application to crash or, if the corrupted data is leveraged appropriately, lead to arbitrary code execution, as classified under CWE‑129.

Affected Systems

The issue is present in ggml‑org:llama.cpp builds from commit b5899 up to, but excluding, b10261. Any deployment that loads GGUF models using a version in this range and does not install the b10261 patch is vulnerable.

Risk and Exploitability

The assigned CVSS score of 8.5 reflects high severity. EPSS data is currently unavailable and the vulnerability is not listed in the CISA KEV catalog. The likely attack vector requires an attacker to supply a specially crafted GGUF file to the target application, whether via direct model upload, file inclusion, or any service that processes external model files. Successful exploitation could cause a crash or, depending on heap state, result in code execution.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Upgrade llama.cpp to release b10261 or newer.
  • Validate GGUF models before loading to ensure token text does not contain negative values or other crafted entries.
  • As a temporary workaround, isolate model loading to a non‑privileged user or sandbox, restricting write access to the heap during processing.

Generated by OpenCVE AI on October 27, 2026 at 08:25 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories available
History
Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'none', 'Technical Impact': 'total'}, 'version': '2.0.3'}

Type Values Removed Values Added
First Time appeared Ggml-org
Ggml-org llama.cpp
Vendors & Products Ggml-org
Ggml-org llama.cpp
Type Values Removed Values Added
Description llama.cpp b5899 before b10261 contains a heap out-of-bounds write vulnerability in llm_tokenizer_plamo2::build that allows attackers to corrupt heap memory via crafted GGUF models. Attackers can supply BYTE-typed token text like <0x-1> whose negative parsed value writes token ids before the bytes_ buffer during model loading, causing crashes or potential code execution.
Title llama.cpp b5899 before b10261 Heap Out-of-Bounds Write via plamo2 Tokenizer
First Time appeared Ggml
Ggml llama.cpp
Weaknesses CWE-129
CPEs cpe:2.3:a:ggml:llama.cpp:*:*:*:*:*:*:*:*
Vendors & Products Ggml
Ggml llama.cpp
References
Metrics cvssV3_1

{'score': 7.8, 'vector': 'CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H'}

cvssV4_0

{'score': 8.5, 'vector': 'CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N'}

Weaknesses
  • CWE-129

    Improper Validation of Array Index

Sources

Status
PUBLISHED
Assigner
VulnCheck
Published
Updated
Oct 31, 2026, 2:24 AM
Reserved
Oct 26, 2026, 10:13 PM
Status
Awaiting Analysis
Published
Oct 27, 2026, 1:19 AM
Modified
Oct 31, 2026, 3:17 AM