Remote code executionin ggml-org llama.cpp.
Proof of concept public (CISAThe US cyber defence agency. Its list names every hole it has seen used in real attacks. assessment).
llama.cpp is an inference of several LLM models in C/C++. In commits 55d4206c8 and prior, the n_discard parameter is parsed directly from JSON input in the llama.cpp server's completion endpoints without validation to ensure it's non-negative. When a negative value is supplied and the context fills up, llama_memory_seq_rm/add receives a reversed range and negative offset, causing out-of-bounds memory writes in the token evaluation loop. This deterministic memory corruption can crash the process or enable remote code execution (RCE). There is no fix at the time of publication.
- No source names a fix yet. Watch this page or the product for updates; we never guess a fixed version.
Not confirmed by any source yet: fixed version not confirmed. We show these as not confirmed instead of guessing.
Affected and fixed versions
From the CVE record, NVD and package advisories. When no source has versions yet, this table says "not confirmed" instead of guessing.
From first report to first attacks
- 5 Jan 2026CVE ID reserved by GitHub_M.
- 7 Jan 2026Published in the CVE List.
- 8 Jan 2026CVE record last updated.
Attack code anyone can find
Exploit maturity: Proof of concept (CISA assessment). CISA assessment (SSVC): exploitation poc.
Listed so defenders can judge how urgent this is and test systems they are authorised to test. Patchminder does not host exploit code; links open the source page. Labels for GitHub repositories come from their public details and are never a promise about the code. Run anything only in an isolated lab.
Report a link
Nothing on this page links to exploit code right now. To report anything else, write to the contact point in the legal notice.
Other llama.cpp vulnerabilities
Same weakness: Out-of-bounds write
- github.com x_refsource_CONFIRM
Patchminder. CVE-2026-21869: Remote code execution in ggml-org llama.cpp. https://patchminder.com/cve/cve-2026-21869/ (accessed 5 December 2026).