Skip to main content

llama.cpp Android CVE-2026-70639

| EUVDEUVD-2026-54278 MEDIUM
NULL Pointer Dereference (CWE-476)
2026-08-06 disclosure@vulncheck.com GHSA-6xfh-c5w2-8vqf
6.8
CVSS 4.0 · Vendor: vulncheck
View

Attack ChainAIDerived

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

  1. Access
    Craft malformed GGUF model file
  2. Delivery
    Deliver file to Android device storage
  3. Exploit
    Induce user to load model in target app
  4. Execution
    app calls bench_1model() in JNI layer
  5. Persist
    null context pointer dereferenced
  6. Impact
    SIGSEGV terminates Android app process

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A10:2025 - Mishandling of Exceptional Conditions
ASVS 5.0
V16 - Security Logging and Error Handling Null pointer safety, defensive checks
MITRE ATT&CK

1 technique across 1 tactic: Impact

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Exploitation requires the following specific conditions: (1) the target application uses the llama.cpp Android JNI wrapper and invokes the bench_1model() benchmarking function - applications that use only inference paths and never call bench_1model() are not affected; (2) the attacker can deliver a malformed, corrupt, or truncated GGUF model file to the Android device's accessible storage; (3) the user must interact to load the malicious model (CVSS UI:P confirms this requirement). The attack vector is local (AV:L), meaning remote-only adversaries without a file delivery mechanism cannot exploit this directly. No authentication is required (PR:N) once file delivery is achieved. Exploitation is strictly bounded to denial-of-service - the CVSS vector explicitly confirms no confidentiality (VC:N) or integrity (VI:N) impact. Applications that validate model file integrity (e.g., checksum verification or source whitelisting) before passing to the JNI layer are not practically exploitable even on unpatched builds.

Impact

The CVSS 4.0 vector (AV:L/AC:L/AT:N/PR:N/UI:P/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N) scores 6.8, reflecting a local attack requiring user interaction with no confidentiality or integrity impact - only high availability impact to the vulnerable system. The local attack vector (AV:L) is the dominant limiting factor: the attacker must deliver a crafted GGUF file to the Android device and induce the user to load it into an application that calls bench_1model(). No EPSS score was provided in the source data, so exploitation probability cannot be quantified. The vulnerability is not in CISA KEV and no POC has been identified, consistent with a low-to-moderate real-world exploitation priority. The blast radius is narrow - a single Android application crash with no lateral movement potential or data exposure. This is a genuine DoS risk for applications that accept model files from untrusted sources but is unlikely to be prioritized over network-exploitable or authenticated-bypass vulnerabilities in most enterprise triage workflows.

Exploit ScenarioDerived

An attacker crafts a malformed GGUF model file designed to cause context initialization failure in llama.cpp and social-engineers a user into loading it via an Android application that uses the llama.cpp JNI wrapper with benchmarking enabled. When bench_1model() is called with the corrupt model, the null context pointer is dereferenced in native code, generating a SIGSEGV that the Android OS uses to kill the application process. No public exploit code has been identified at time of analysis, but the mechanics are straightforward for any developer familiar with GGUF format structure.

This Month Plan within 30 days. Why: MEDIUM severity (CVSS 4.0-6.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 06, 2026

Null pointer dereference in the llama.cpp LLaMA-Android JNI wrapper's bench_1model() function allows denial of service via a crafted model file. Builds b1886 through b7445 (packaged releases 0.9.0-0.17.1) are affected; the function skips null validation on the model context pointer before dereferencing it, so supplying a malformed or truncated GGUF model file triggers a SIGSEGV that terminates the Android application process. No public exploit has been identified at time of analysis and this is not listed in CISA KEV, but the attack path is mechanically simple for anyone able to deliver a crafted model to the device.

RemediationAI

Upgrade to llama.cpp build b7446 or later, available at https://github.com/ggml-org/llama.cpp/releases/tag/b7446 - this is the vendor-released patched build. The upstream fix commit is https://github.com/ggml-org/llama.cpp/commit/5c0d18881e0e9794c96b2602736b758bac9d9388. If an immediate upgrade is not possible, restrict the Android application to loading GGUF model files exclusively from trusted, integrity-verified sources (e.g., pre-validated SHA-256 checksums before passing to JNI) and disable or gate access to the bench_1model() benchmarking code path if it is not required in production builds. Adding an application-layer null check before calling bench_1model() is a viable short-term compensating control but does not address the root cause in the native layer. Note that the provided commit diff primarily shows build system and documentation changes; the precise null-check code fix may be in a file not fully captured in the supplied diff - verify the patched build independently before marking remediation complete.

Affected VersionsENISA

llama.cpp b1886 ≤b7445
llama.cpp 0.9.0 ≤0.17.1

Affected Packages

euvd llama_cpp no fix

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in euvd

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

Technical ContextAI · show details

llama.cpp exposes native C++ LLM inference to Android applications through a JNI (Java Native Interface) bridge in the examples/llama.android directory. The bench_1model() function performs model benchmarking within this native layer but omits a null guard on the model context pointer returned from context initialization. When GGUF model loading fails - due to corruption, truncation, or deliberate malformation - the initialization returns null, and the subsequent dereference in bench_1model() raises a SIGSEGV, which the Android OS delivers as an unhandled signal that terminates the process. CWE-476 (NULL Pointer Dereference) identifies this as a missing precondition check at a trust boundary between user-supplied model data and native code. The EUVD-2026-54278 entry corroborates the affected build range b1886-b7445 and the corresponding semantic version range 0.9.0-0.17.1.

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 (vulncheck) PRIMARY 6.8 MEDIUM
CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:P/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N
vuln.today AI 5.5 MEDIUM

Local delivery of crafted model file required (AV:L); user must load the file (UI:R); no authentication needed (PR:N); impact is application crash only, no data exposure (C:N/I:N/A:H).

3.1 AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H
4.0 AV:L/AC:L/AT:N/PR:N/UI:P/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N
SUSE MEDIUM
Red Hat 5.5 MEDIUM

Primary rating from Vendor (vulncheck).

CVSS VectorVendor: vulncheck

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

DescriptionCVE.org

llama.cpp builds b1886 through b7445 contain a null pointer dereference vulnerability in the LLaMA-Android JNI wrapper where the bench_1model() function fails to validate the model context pointer before dereferencing it. Attackers can supply a malicious, corrupt, or truncated model file to trigger a null context condition, causing a SIGSEGV crash that terminates the Android application process and results in denial of service.

Threat Intelligence Overview

EPSS Score
0.1%
Top 97% exploitable
Prevalence
Medium
widely used open-source LLM inference library, growing Android deployment base
Data Quality
9 sources
Confidence: High
EUVD NVD CVE.org EPSS Vulnrichment Vendor CIRCL 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 MEDIUM
CISA KEV No
Public POC No
EPSS 0.1%
Patch available No
Active threat No
Deciding rule
MEDIUM severity (CVSS 4.0-6.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
None
System Exposure· derived
Small
Automatable
No
Human Impact· derived
Medium
Technical Impact
Partial

Priority Score

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

Attack Technique

A null pointer dereference occurs when a program attempts to access memory through a pointer that has been set to NULL (address 0x0).

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

Vendor StatusVendor

SUSE

Severity: Moderate

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