CVE-2026-137057
llama.cpp b7118 before b12604 Integer Underflow in Grammar Parser parse_sequence
Description
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.
INFO
Published Date :
Nov. 25, 2026, 7:33 p.m.
Last Modified :
Nov. 25, 2026, 7:33 p.m.
Remotely Exploit :
Yes !
Source :
VulnCheck
CVSS Scores
| Score | Version | Severity | Vector | Exploitability Score | Impact Score | Source |
|---|---|---|---|---|---|---|
| CVSS 3.1 | HIGH | 83251b91-4cc7-4094-a5c7-464a1b83ea10 | ||||
| CVSS 3.1 | HIGH | MITRE-CVE | ||||
| CVSS 4.0 | HIGH | 83251b91-4cc7-4094-a5c7-464a1b83ea10 |
Solution
- Update llama.cpp to version b12604 or later.
- Ensure grammars use valid min/max repetition ranges.
- Validate user-supplied grammar input carefully.
- Monitor server resource usage.
We scan GitHub repositories to detect new proof-of-concept exploits. Following list is a collection of public exploits and proof-of-concepts, which have been published on GitHub (sorted by the most recently updated).
Results are limited to the first 15 repositories due to potential performance issues.
The following list is the news that have been mention
CVE-2026-137057 vulnerability anywhere in the article.