highCVSS 7.1NVD status: Analyzed

CVE-2024-32878

Llama.cpp is LLM inference in C/C++.

Componentllama.cpp
Severityhigh (CVSS 7.1)
CVSS vectorCVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:H/A:L
Published (NVD)2024-04-26
Last modified2026-06-17
Affected versions
llama.cpp >= b2715, < b2740
Fixed inb2740
WeaknessCWE-456
CISA KEVnot listed

NVD description

Llama.cpp is LLM inference in C/C++. There is a use of uninitialized heap variable vulnerability in gguf_init_from_file, the code will free this uninitialized variable later. In a simple POC, it will directly cause a crash. If the file is carefully constructed, it may be possible to control this uninitialized value and cause arbitrary address free problems. This may further lead to be exploited. Causes llama.cpp to crash (DoS) and may even lead to arbitrary code execution (RCE). This vulnerability has been patched in commit b2740.

Does CVE-2024-32878 hit the version you run?Paste your docker-compose.yml, requirements.txt or package.json. The scanner checks your pinned versions against this CVE and every other one we track for llama.cpp.
Check my stack

What to do

  • Upgrade llama.cpp to b2740 or later.
  • Do not expose the component's API or UI to the internet without authentication in front of it.

Sources

Other llama.cpp CVEs

All llama.cpp CVEs