CVE-2026-70638: llama.cpp b1886–b7445 Integer Overflow via new_1batch() in llama-android.cpp

Published Aug 6, 2026
·
Updated

llama.cpp builds b1886 through b7445 contain an integer overflow vulnerability in the LLaMA-Android JNI wrapper where the new1batch() function multiplies sizeof(llamaseqid) by an attacker-controlled nseqmax parameter without overflow validation, causing heap buffer allocation to wrap and allocate insufficient memory. Attackers can exploit this by providing a crafted nseqmax value through a malicious model file or JNI call to trigger heap corruption and achieve denial of service or arbitrary code execution on Android applications using the LLaMA-Android binding.

Affected Software

1 affected component
llama.cpp>b1886<=b7445

Event History

Aug 6, 2026
CVE Published
via MITRE·03:35 PM
Data Sourced
via MITRE·03:35 PM
DescriptionSeverityWeakness
Data Sourced
via NVD·10:18 PM
DescriptionSeverityWeakness
Free Weekly Intel

Don't miss critical vulnerabilities

Join thousands of security professionals who receive our weekly digest of trending CVEs, zero-days, and exploited vulnerabilities.

No spam. Unsubscribe anytime.

Frequently Asked Questions

1

What is the severity of CVE-2026-70638?

The severity of CVE-2026-70638 is rated high with a score of 7.8.

2

What is the risk associated with CVE-2026-70638?

CVE-2026-70638 has a risk rating of 68, indicating significant potential for exploitation.

3

How do I fix CVE-2026-70638?

To fix CVE-2026-70638, upgrade to versions of llama.cpp beyond b7445 which contain the necessary patches.

4

What type of vulnerability is CVE-2026-70638?

CVE-2026-70638 is categorized as an integer overflow vulnerability.

5

Which function is affected in CVE-2026-70638?

The integer overflow vulnerability in CVE-2026-70638 is found in the new_1batch() function in llama-android.cpp.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203