CVE-2026-33298: llama.cpp has a Heap Buffer Overflow via Integer Overflow in GGUF Tensor Parsing
llama.cpp is an inference of several LLM models in C/C++. Prior to b7824, an integer overflow vulnerability in the ggmlnbytes function allows an attacker to bypass memory validation by crafting a GGUF file with specific tensor dimensions. This causes ggmlnbytes to return a significantly smaller size than required (e.g., 4MB instead of Exabytes), leading to a heap-based buffer overflow when the application subsequently processes the tensor. This vulnerability allows potential Remote Code Execution (RCE) via memory corruption. b7824 contains a fix.
Affected Software
Event History
Frequently Asked Questions
What is the severity of CVE-2026-33298?
CVE-2026-33298 has been classified as a high-severity vulnerability due to its potential to cause a heap buffer overflow leading to memory corruption.
How do I fix CVE-2026-33298?
To fix CVE-2026-33298, upgrade your llama.cpp software to version b7824 or later.
What is the impact of CVE-2026-33298?
CVE-2026-33298 can allow attackers to execute arbitrary code or crash the application by exploiting the heap buffer overflow.
What component is affected by CVE-2026-33298?
CVE-2026-33298 affects the `ggml_nbytes` function in the llama.cpp inference library.
Is CVE-2026-33298 related to any specific file type?
Yes, CVE-2026-33298 is related to GGUF files, which can be crafted to exploit the integer overflow vulnerability.