Skip to main content

llama.cpp CVE-2026-18581

| EUVDEUVD-2026-52018 LOW
Reachable Assertion (CWE-617)
2026-08-03 VulDB GHSA-3732-9c5p-7h79
1.9
CVSS 4.0 · Vendor: VulDB
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Obtain low-privileged local account
  2. Delivery
    Craft malformed Jinja template input {{9|9|{
  3. Exploit
    Submit template to llama.cpp parser
  4. Execution
    Trigger reachable assertion in common/jinja/parser.cpp
  5. Impact
    Process aborts, denying inference service

Vulnerability Assessment

Weakness
CWE
ASVS 5.0
V16 - Security Logging and Error Handling Reachable assertion handling
Exploitation Conditions

Exploitation requires local access to the system running llama.cpp and a low-privileged OS account (PR:L per CVSS 4.0 vector). The attacker must be able to supply template input directly to the llama.cpp Jinja template parser - specifically the input {{9|9|{ or a similar malformed filter-chain sequence. This limits exploitation to environments where untrusted users can submit template strings to llama.cpp, such as shared inference endpoints or developer workstations where multiple users have shell access. Exploitation is constrained by: local-only attack surface (no network-exploitable path), low-privilege requirement (a valid OS account is needed), and impact limited to crashing the llama.cpp process with no code execution or data access. Default single-user desktop deployments face negligible risk since the user running llama.cpp can already crash the process through normal OS mechanisms.

Impact

Real-world risk is low. The CVSS 4.0 score of 1.9 accurately reflects the limited blast radius: exploitation is strictly local (AV:L), requires low privileges (PR:L), and produces only a local availability impact (VA:L) with no confidentiality or integrity consequences (VC:N/VI:N). There is no network-exploitable surface and no data exfiltration path. The existence of a public POC (E:P in the CVSS 4.0 supplemental metrics) raises the likelihood of exploitation slightly but does not change the impact profile. The vulnerability is not listed in CISA KEV, and no EPSS data was provided. SSVC signals: exploitation is possible but not widespread; the attack is not automatable at scale due to the local access requirement; technical impact is partial (availability only). This is a genuine but low-severity local DoS - not a priority unless llama.cpp is deployed in a multi-user or shared inference environment where untrusted users can supply template inputs. The primary risk scenario is a denial-of-service against a local AI inference service rather than remote compromise.

Exploit ScenarioDerived

A low-privileged local user on a system running llama.cpp as a shared inference service crafts a prompt template containing the malformed filter chain {{9|9|{ and submits it to the llama.cpp process. The Jinja Minja parser in common/jinja/parser.cpp hits the reachable assertion, causing the process to abort immediately. A public proof-of-concept demonstrating this crash is available on Proton Drive (linked in the VulDB submission), confirming the reproducibility of the crash sequence.

Monitor Track and reassess. Why: LOW severity (CVSS 0.1-3.9).
No patch listed yet 0.1% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Aug 03, 2026

Reachable assertion in llama.cpp's Jinja Minja Template Parser crashes the process when processing a maliciously crafted template input. The flaw, located in common/jinja/parser.cpp, is triggered locally by a low-privileged user supplying the input sequence {{9|9|{ to the template engine, causing an unhandled assertion failure and denial of service. A public proof-of-concept exploit has been disclosed; the project was notified via GitHub issue #25282 but has not issued a patch or response as of this writing.

RemediationAI

No vendor-released patch identified at time of analysis - the project has not responded to the disclosure via GitHub issue https://github.com/ggml-org/llama.cpp/issues/25282. As a compensating control, operators should restrict the ability for untrusted or low-privileged users to supply arbitrary Jinja template inputs to llama.cpp inference processes; this directly eliminates the attack path since exploitation requires local template submission. In multi-user inference deployments, input validation or allowlisting on template content (blocking malformed filter-chain syntax such as {{...|...|{) can serve as a filter-level workaround, though parser-level sanitization is non-trivial and may introduce false positives on legitimate templates. Running llama.cpp under a process supervisor (e.g., systemd with Restart=on-failure) mitigates the availability impact by enabling automatic restart after a crash. Monitor the GitHub repository and VulDB entry at https://vuldb.com/cve/CVE-2026-18581 for patch availability.

Affected VersionsENISA

llama.cpp e15efe0

Affects your stack

Find out whether the stacks and servers you run are on an affected version.

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

llama.cpp (cpe:2.3:a:ggml-org:llama.cpp:*:*:*:*:*:*:*:*) is an open-source C/C++ inference engine for large language models developed by ggml-org. The affected component is its embedded Jinja2-compatible template parser ('Minja'), used to render prompt templates at inference time. CWE-617 (Reachable Assertion) describes a class of defects where a debug or defensive assertion - intended to catch programmer errors - can be reached via user-controlled input. In this case, the input {{9|9|{ produces a parser state that satisfies a failing assertion condition, causing the process to call abort() or equivalent, immediately terminating the application. This is a parser logic defect in the Jinja template tokenizer or AST construction phase, specific to the commit e15efe0 of the ggml-org repository.

Know when Llama Cpp gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (VulDB) PRIMARY 1.9 MEDIUM
CVSS:4.0/AV:L/AC:L/AT:N/PR:L/UI:N/VC:N/VI:N/VA:L/SC:N/SI:N/SA:N/E:P
vuln.today AI 3.3 LOW

Local access and low privileges required to submit template input; impact is crash only, no confidentiality or integrity consequence.

3.1 AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:L
4.0 AV:L/AC:L/AT:N/PR:L/UI:N/VC:N/VI:N/VA:L/SC:N/SI:N/SA:N

Primary rating from Vendor (VulDB).

CVSS VectorVendor: VulDB

Attack Vector
Local
Attack Complexity
Low
Attack Requirements
None
Privileges Required
Low
User Interaction
None
Vulnerable system: Confidentiality
None
Vulnerable system: Integrity
None
Vulnerable system: Availability
Low
Subsequent system: Confidentiality
None
Subsequent system: Integrity
None
Subsequent system: Availability
None

Lifecycle Timeline

3
Severity Changed
Aug 03, 2026 - 01:22 NVD
MEDIUM LOW
CVSS changed
Aug 03, 2026 - 01:22 NVD
4.8 (MEDIUM) 1.9 (LOW)
CVE Published
Aug 03, 2026 - 00:30 cve.org
LOW 1.9

DescriptionCVE.org

A vulnerability was determined in ggml-org llama.cpp e15efe0. Affected by this issue is some unknown functionality of the file common/jinja/parser.cpp of the component Jinja Minja Template Parser. Executing a manipulation with the input {{9|9|{ can lead to reachable assertion. The attack requires local access. The exploit has been publicly disclosed and may be utilized. The project was informed of the problem early through an issue report but has not responded yet.

Threat Intelligence Overview

EPSS Score
0.1%
Top 98% exploitable
Prevalence
Medium
widely used open-source LLM inference engine in AI developer community
Exploit
POC
Public exploit code exists
Data Quality
7 sources
Confidence: High
EUVD NVD CVE.org EPSS Vulnrichment GitHub VulDB

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity LOW
CISA KEV No
Public POC Yes
EPSS 0.1%
Patch available No
Active threat No
Deciding rule
LOW severity (CVSS 0.1-3.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Defer
Exploitation
Poc
System Exposure· derived
Small
Automatable
No
Human Impact· derived
Low
Technical Impact
Partial

Priority Score

30
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +10
PoC: +20
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Denial of Service attacks render applications or systems unavailable by overwhelming resources or triggering failure conditions.

CVE-2024-42479 CRITICAL POC
10.0 Aug 12

Arbitrary memory write in llama.cpp's RPC server allows remote unauthenticated attackers to corrupt arbitrary memory add

CVE-2024-21802 HIGH POC
8.8 Feb 26

Remote code execution in llama.cpp (commit 18c2e17) is possible when a user opens a malicious .gguf model file, triggeri

CVE-2026-21869 HIGH POC
8.8 Jan 08

Llama.cpp server endpoints fail to validate the n_discard parameter from JSON input, allowing negative values that trigg

CVE-2024-21825 HIGH POC
8.8 Feb 26

Remote code execution in llama.cpp (commit 18c2e17) is possible when a victim loads a malicious .gguf model file, trigge

CVE-2024-23605 HIGH POC
8.8 Feb 26

Remote code execution in llama.cpp (GGUF library) allows attackers to achieve arbitrary code execution by tricking a use

CVE-2024-23496 HIGH POC
8.8 Feb 26

Remote code execution in llama.cpp (commit 18c2e17) occurs when the GGUF library's gguf_fread_str function parses a mali

CVE-2024-21836 HIGH POC
8.8 Feb 26

Heap-based buffer overflow in llama.cpp's GGUF library header parser (commit 18c2e17) enables code execution when a vict

CVE-2025-52566 HIGH POC
8.6 Jun 24

CVE-2025-52566 is a signed vs. unsigned integer overflow vulnerability in llama.cpp's tokenizer (llama_vocab::tokenize f

CVE-2026-34159 CRITICAL
9.8 Apr 01

Remote code execution in llama.cpp RPC backend allows unauthenticated attackers with TCP access to achieve arbitrary mem

CVE-2024-42478 MEDIUM POC
5.3 Aug 12

llama.cpp provides LLM inference in C/C++. Rated medium severity (CVSS 5.3), this vulnerability is remotely exploitable,

CVE-2026-43629 CRITICAL
9.2 Aug 06

Heap buffer overflow in llama.cpp's server KV cache state-restore path (builds b4882 through b9058) lets an attacker who

CVE-2026-118375 CRITICAL
9.2 Oct 28

Stack-based out-of-bounds write in llama.cpp's ggml-rpc RDMA receive path (builds b8841 through b11865) lets unauthentic

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy