CVE-2026-137057
High 7.5 P4 · Monitor (22/100)llama.cpp from b7118 before b12604 contains an integer underflow vulnerability in llama_grammar_parser::parse_sequence() that allows unauth…
Confirmed facts from the sources
- CVSS
- 7.5 (High) · CVSS 3.1
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
Scored by disclosure@vulncheck.com - Exploitation confirmed
- Not in the CISA KEV catalog
- Exploitation estimated (EPSS)
- 1.27 % · percentile 69.9 % (as of 29.11.2026)
Probability of exploitation in the next 30 days – an estimate by FIRST, not confirmation. - Public exploit
- No reference to a public exploit.
- Fix
- No fix known
- Monitored technologies
- No monitored technology
Description (source)
llama.cpp from b7118 before b12604 contains an integer underflow vulnerability in llama_grammar_parser::parse_sequence() that allows unauthenticated remote attackers to cause denial of service by supplying GBNF repetitions with max lower than min. Attackers can send a grammar like {5,2} in the grammar field of a llama-server /completion request, wrapping n_opt to generate endless repetition rules that hang the process and exhaust memory.
Affected products and versions
| Vendor / product | Affected versions | Fixed in | Source |
|---|---|---|---|
| github: ggml-org/llama.cpp | >= b7118, < b12604 | — | nvd |
Versions as published. “Fixed in” only where a source names the version explicitly.
Recommended mitigation
The sources name no fix or mitigation yet.
In general: check your versions, update to a fixed version, limit exposure until then and follow the vendor guidance.
AI interpretation
No AI interpretation yet – it is created for urgent advisories of monitored technologies. The facts above apply regardless.
Why this priority?: P4 · Monitor (22/100)
- Estimated exploitation probability 1.27 % (EPSS, percentile 69.9 %) – an estimate, not confirmation (+5)
- Technical severity: CVSS 7.5 (HIGH) – on its own not a reason for top priority (+12)
- No fix known – mitigations needed (+5)
Priority is a general assessment from CVSS, KEV, EPSS, exploits, relevance and fix availability. Whether a specific environment is affected depends on its versions, configuration and exposure.
Original advisories and links
- Advisory https://nvd.nist.gov/vuln/detail/CVE-2026-137057 · nvd
- Reference https://github.com/ggml-org/llama.cpp/blob/b12603/src/llama-grammar.cpp#L519-L522 · disclosure@vulncheck.com
- Reference https://github.com/ggml-org/llama.cpp/commit/46eb1742db6d2caec1bfa848c5702b1bdcc815e5 · disclosure@vulncheck.com
- Reference https://github.com/ggml-org/llama.cpp/issues/32550 · disclosure@vulncheck.com
- Reference https://github.com/ggml-org/llama.cpp/pull/32551 · disclosure@vulncheck.com
- Reference https://github.com/ggml-org/llama.cpp/releases/tag/b12604 · disclosure@vulncheck.com
- Reference https://www.vulncheck.com/advisories/llama-cpp-b7118-before-b12604-integer-underflow-in-gr… · disclosure@vulncheck.com