---
id: CVE-2026-43627
title: >-
  llama.cpp builds b1283 through b9058 contain an integer overflow vulnerability
  in the llama_batch_init() function where unchecked multiplications in malloc()
  calls can wrap past INT32_MAX when computing allocation sizes
summary: >-
  llama.cpp builds b1283 through b9058 contain an integer overflow vulnerability
  in the llama_batch_init() function where unchecked multiplications in malloc()
  calls can wrap past INT32_MAX when computing allocation sizes. Attackers can
  pa…
severity: high
cvss: 7.8
cvssVector: 'CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H'
cwe:
  - CWE-190
  - CWE-680
vendor: ggml
product: llama.cpp
affected:
  - 'llama.cpp >= b1283, <= b9058'
published: '2026-08-06'
updated: '2026-09-21'
sourceUpdated: '2026-09-21T18:12:04.687'
source: NVD
sourceUrl: 'https://nvd.nist.gov/vuln/detail/CVE-2026-43627'
references:
  - url: 'https://github.com/Vladimir-tokarev-cyera/llama-cpp-security-patches'
    label: disclosure@vulncheck.com
  - url: >-
      https://www.vulncheck.com/advisories/llama-cpp-b1283-b9058-integer-overflow-in-llama-batch-init-function
    label: disclosure@vulncheck.com
tags:
  - nvd
epss: 0.00201
epssPercentile: 0.08967
ingestedAt: '2026-08-08T22:30:38.891Z'
---

## Overview

llama.cpp builds b1283 through b9058 contain an integer overflow vulnerability in the llama_batch_init() function where unchecked multiplications in malloc() calls can wrap past INT32_MAX when computing allocation sizes. Attackers can pass specially crafted parameters to trigger integer overflow, causing heap corruption and potentially achieving arbitrary code execution through subsequent batch operations that write past allocated buffer boundaries.

## Affected

- `llama.cpp >= b1283, <= b9058`

## Remediation

Refer to the linked advisories for vendor-supplied fixes and affected version ranges.
