Description
llama.cpp b5693 and before is vulnerable to Uncontrolled Recursion in common/json-schema-to-grammar.cpp, resulting in a denial of service.
Published: 2026-09-01
Score: 7.5 High
EPSS: n/a
KEV: No
Impact: n/a
Action: n/a
AI Analysis

Impact

The vulnerability stems from uncontrolled recursion in the json-schema-to-grammar.cpp component of llama.cpp, a flaw classified as CWE-674. When triggered, the recursion can exhaust stack or heap resources, causing the application to crash or become unresponsive, which results in a denial of service attack. This weakness is limited to the parsing logic and does not provide direct code execution or data exfiltration capabilities.

Affected Systems

llama.cpp releases b5693 and earlier are affected. The vulnerability resides in common/json-schema-to-grammar.cpp of those versions, and any deployment that compiles or runs these releases may be impacted.

Risk and Exploitability

The CVSS score of 7.5 indicates a high severity and the EPSS score is not available, so the current exploitation likelihood is unknown but could be moderate to high if the component is exposed. The vulnerability is not listed in the CISA KEV catalog. Based on the description, it is inferred that the attack vector requires supplying a crafted JSON schema to the parser, which could be done directly if the application processes user‑supplied schemas or indirectly through a service that accepts such input. Once triggered, the attacker can force the application to consume excessive resources, degrading service availability.

Generated by OpenCVE AI on September 2, 2026 at 01:12 UTC.

Remediation

No vendor fix or workaround currently provided.

OpenCVE Recommended Actions

  • Upgrade to a llama.cpp release newer than b5693 where the recursion issue has been fixed.
  • Apply any patches or pull requests from the llama.cpp GitHub repository that address the uncontrolled recursion in common/json-schema-to-grammar.cpp.
  • If upgrading immediately is not possible, restrict or delete the json‑schema parsing functionality from the application or wrap the input in strict validation to limit recursion depth.

Generated by OpenCVE AI on September 2, 2026 at 01:12 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories yet.

History

Wed, 02 Sep 2026 01:30:00 +0000

Type Values Removed Values Added
Title Denial of Service via Uncontrolled Recursion in llama.cpp Json Schema Grammar Parser

Wed, 02 Sep 2026 00:30:00 +0000

Type Values Removed Values Added
First Time appeared Ggml-org
Ggml-org llama.cpp
Vendors & Products Ggml-org
Ggml-org llama.cpp

Tue, 01 Sep 2026 22:00:00 +0000

Type Values Removed Values Added
Description llama.cpp b5693 and before is vulnerable to Uncontrolled Recursion in common/json-schema-to-grammar.cpp, resulting in a denial of service.
Weaknesses CWE-674
References
Metrics cvssV3_1

{'score': 7.5, 'vector': 'CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H'}


Subscriptions

Ggml-org Llama.cpp
cve-icon MITRE

Status: PUBLISHED

Assigner: mitre

Published:

Updated: 2026-09-01T18:20:16.537Z

Reserved: 2026-06-08T00:00:00.000Z

Link: CVE-2026-52130

cve-icon Vulnrichment

No data.

cve-icon NVD

Status : Received

Published: 2026-09-01T18:17:43.603

Modified: 2026-09-01T19:17:24.247

Link: CVE-2026-52130

cve-icon Redhat

No data.

cve-icon OpenCVE Enrichment

Updated: 2026-09-02T01:15:05Z

Weaknesses