Cyber Resilience

CVE-2024-42479

Memory Safety in Ggml Llama.Cpp ≤ b3561

Public PoCMemory Safety
Published
12 August 2024
Modified
27 April 2026
Patch / advisory
CVSS Score v3.1 10.0
Click a component to see what it means
Raw vectorCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:H/A:H
EPSS Score 0.026 84th percentile
Risk Priority 81 floored blend · peak EPSS

Summary

CVE-2024-42479 is a critical-severity Write-what-where Condition (CWE-123) vulnerability in Ggml Llama.Cpp. Its CVSS base score is 10.0 (Critical).

Operationally, exploitation aligns with the MITRE ATT&CK technique Exploitation for Privilege Escalation (T1068); ranked in the top 16% of CVEs by exploit likelihood; it is not currently listed in the CISA KEV catalog; a public proof-of-concept is referenced.

This vulnerability is AI-related — categorised as NLP and Transformers; in the Other ATLAS/OWASP Terms risk domain.

The strongest mitigations our analysis identified map to SA-11 (Developer Testing and Evaluation) and SI-16 (Memory Protection) — see the control section below for these in your framework.

Deeper analysis AI-assisted summary

Synthesised by an AI model from the NVD description and linked references — a reading aid, not an authoritative source.

llama.cpp, a C/C++ library providing LLM inference, is affected by CVE-2024-42479, a flaw in the rpc_tensor structure. The unsafe data pointer member permits arbitrary address writing, corresponding to CWE-123 and CWE-787, and carries a CVSS 3.1 score of 10.0 reflecting network-reachable impact with high consequences for confidentiality, integrity, and availability plus scope change.

An unauthenticated remote attacker can supply crafted RPC data to trigger the write primitive, achieving arbitrary memory modification that may lead to code execution or full host compromise in affected deployments.

The issue is resolved in commit b3561, per the associated GitHub security advisory GHSA-wcr5-566p-9cwj, which directs users to apply the patch.

EPSS remains low at a current value of 0.0568 with a peak of 0.0586 and shows no material rise; the vulnerability is relevant to AI/ML environments that expose llama.cpp RPC interfaces for distributed inference.

EU & UK References

Vulnerability Data

llama.cpp provides LLM inference in C/C++. The unsafe `data` pointer member in the `rpc_tensor` structure can cause arbitrary address writing. This vulnerability is fixed in b3561.

CWE(s)

AI Security AnalysisAI

AI Category
NLP and Transformers
Risk Domain
Other ATLAS/OWASP Terms
OWASP Top 10 for LLMs 2025
None mapped
Classification Reason
llama.cpp is a C/C++ library specifically for LLM (Large Language Model) inference, which relies on transformer architectures central to NLP tasks.

Related Threats

MITRE ATT&CK Enterprise Techniques

T1068 Exploitation for Privilege Escalation Privilege Escalation
Adversaries may exploit software vulnerabilities in an attempt to elevate privileges.
T1190 Exploit Public-Facing Application Initial Access
Adversaries may attempt to exploit a weakness in an Internet-facing host or system to initially access a network.
T1203 Exploitation for Client Execution Execution
Adversaries may exploit software vulnerabilities in client applications to execute code.
T1210 Exploitation of Remote Services Lateral Movement
Adversaries may exploit remote services to gain unauthorized access to internal systems once inside of a network.
T1211 Exploitation for Stealth Stealth
Adversaries may exploit vulnerabilities to evade detection by hiding activity, suppressing logging, or operating within trusted or unmonitored components.
T1212 Exploitation for Credential Access Credential Access
Adversaries may exploit software vulnerabilities in an attempt to collect credentials.
Derived from this CVE’s CWE(s) via the direct CWE→ATT&CK cross-walk.

CVEs Like This One

CVE-2024-23496Same product: Ggml Llama.Cpp
CVE-2024-21836Same product: Ggml Llama.Cpp
CVE-2024-21825Same product: Ggml Llama.Cpp
CVE-2024-23605Same product: Ggml Llama.Cpp
CVE-2024-21802Same product: Ggml Llama.Cpp
CVE-2024-47438Shared CWE-123, CWE-787
CVE-2024-20741Shared CWE-123, CWE-787
CVE-2026-46300Shared CWE-123, CWE-787
CVE-2026-43500Shared CWE-123, CWE-787
CVE-2024-20141Shared CWE-123, CWE-787

Affected Assets

ggml
llama.cpp
≤ b3561

Mitigating Controls

Control response

Prevent
Stop it (NIST 800-53)

Detect
Catch it (NIST detect / respond)

Harden
Shrink the surface (DISA STIG)
  • 4 hardening rules · 4 OS baselines
Validate
Prove the fix (OWASP ASVS)

Mitigating Controls (NIST 800-53 r5) AI

Developer testing and evaluation (including fuzzing and bounds checks) finds out-of-bounds write flaws before deployment.

Memory-protection mechanisms block unauthorized writes to arbitrary locations even if a write-what-where primitive exists.

Requiring documented secure-development standards and tools can mandate bounds-checked coding practices that avoid the weakness.

Secure engineering principles require memory-safe coding and bounds checking that eliminate the root cause of write-what-where flaws.

Process isolation confines the blast radius of an arbitrary write so it cannot affect other domains.

Input validation directly stops malformed data from triggering buffer overflows that produce arbitrary write-what-where conditions.

Mitigating Controls (NIST CSF 2.0) AI

Derived directly from the weakness types (CWEs) cited in the NVD entry via our AI-authored CWE→CSF cross-walk (authority under review) — links open the control.

PR.PS-06 mostly match
prevents

Secure SDLC practices directly prevent arbitrary write conditions via safe coding, bounds checking, and memory-safe constructs.

ID.RA-01 partial match
prevents

Vulnerability scanning and recording can discover out-of-bounds write flaws so they can be remediated.

PR.PS-02 partial match
prevents

Patching or replacing vulnerable software directly eliminates known instances of this coding weakness.

Mitigating Controls (ISO/IEC 27001:2022 Annex A) AI

Derived directly from the weakness types (CWEs) cited in the NVD entry via our AI-authored CWE→ISO cross-walk (authority under review) — links open the control.

finds

Security testing in development and acceptance can detect write-what-where conditions before deployment.

prevents

Secure development lifecycle practices directly reduce the likelihood of write-what-where flaws such as buffer overflows.

prevents

Application security requirements can mandate input validation and bounds checking that mitigate arbitrary write conditions.

prevents

Secure architecture and engineering principles discourage unsafe memory handling that leads to write-what-where vulnerabilities.

prevents

Secure coding standards explicitly forbid unsafe buffer operations that enable arbitrary memory writes.

prevents

Change management processes help ensure security fixes for such weaknesses are properly deployed.

Hardening callouts derived

Configuration rules from DISA STIG baselines that bear on weaknesses of the type cited by this CVE. Each rule is shown with the relationship its mapping actually records, against the CWE it was authored against. Derived via CVE→CWE over `controls_xwalks` (authoritative rows only; rows rated `none` are excluded).

Oracle Linux 8 (1 rule)
  • V-248592 OL 8 must clear memory when it is freed to prevent use-after-free attacks. prevents CWE-123
RHEL 8 (1 rule)
  • V-230279 RHEL 8 must clear memory when it is freed to prevent use-after-free attacks. prevents CWE-123
Windows 10 (1 rule)
  • V-220727 Structured Exception Handling Overwrite Protection (SEHOP) must be enabled. prevents CWE-123
Windows 11 (1 rule)
  • V-253284 Structured Exception Handling Overwrite Protection (SEHOP) must be enabled. prevents CWE-123

References