CVE-2026-43622 Details
Description
llama.cpp builds b1886 through b7445 contain a double free vulnerability in the LLaMA-Android JNI wrapper where new_1batch() allocates memory using malloc() while free_1batch() deallocates it using the C++ delete operator, causing heap metadata corruption. Attackers can trigger this memory management mismatch to cause denial of service through process crashes or potentially achieve arbitrary code execution depending on allocator state.
A double free vulnerability has been identified in llama.cpp versions b1886 through b7445, specifically within the LLaMA-Android JNI wrapper. The issue arises because the function new_1batch() allocates memory using malloc(), while free_1batch() deallocates it using the C++ delete operator. This mismatch in memory management leads to heap metadata corruption. Attackers can exploit this vulnerability to cause a denial-of-service by crashing the process or potentially achieve arbitrary code execution, depending on the state of the memory allocator.
Users can apply the patch available in the 'llama-cpp-security-patches' repository by following the instructions provided in the repository's README file.
Metrics
CVSS 4.0 Severity and Vector Strings:
CVSS 3.x Severity and Vector Strings:
No data available for CVSS Version 2.0 on this CVE.
CISA-ADP
Assessed Aug 6, 2026References to Advisories, Solutions, and Tools
By selecting these links, you will be leaving this site. These are references gathered from the official CVE record and are not endorsed by Volerion.
| URL | Source(s) | Tag(s) |
|---|---|---|
| https://github.com/ggml-org/llama.cpp/commit/5c0d18881e0e9794c96b2602736b758bac9d9388 | [email protected] | Patch |
| https://github.com/ggml-org/llama.cpp/releases/tag/b7446 | [email protected] | PatchRelease NotesVendor Advisory |
| https://github.com/Vladimir-tokarev-cyera/llama-cpp-security-patches | [email protected] | PatchThird Party Advisory |
| https://www.vulncheck.com/advisories/llama-cpp-b1886-b7445-double-free-via-llama-android-cpp | [email protected] | PatchThird Party Advisory |
Weakness Enumeration
| CWE-ID | CWE Name | Source |
|---|---|---|
| CWE-415 | Double Free | [email protected] |
| CWE-762 | Mismatched Memory Management Routines | [email protected] |
Affected Products
| Product | Versions |
|---|---|
| ggml llama.cpp | >= b1886, <= b7445 |
CPE
Remediation
| |
Change History
5 change records found show changes
| Date | Action | Recorded By |
|---|---|---|
| Sep 4, 2026 | Initial Analysis | [email protected] |
| Aug 7, 2026 | CVE Modified | [email protected] |
| Aug 6, 2026 | CVE Modified | [email protected] |
| Aug 6, 2026 | CVE Modified | CISA-ADP |
| Aug 6, 2026 | New CVE Received | [email protected] |