CVE-2026-13573: LLVM Stack Buffer Overflow in StringMap – Analysis & Patch Guidance
A stack-based buffer overflow vulnerability has been reported in LLVM's StringMap insertion function within the ValueSymbolTable module. The issue affects LLVM versions up to 22.1.6 and requires local access to exploit. Notably, the LLVM project has stated this behavior falls outside their documented security scope and is not considered a security vulnerability by the maintainers. Exploit code has been publicly disclosed, though verification of the vulnerability's actual exploitability remains uncertain.
Source data · NVD / CISA · public domain
- CVSS
- 3.1 · 3.3 LOW · CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:L
- Weaknesses (CWE)
- CWE-119, CWE-121
- Affected products
- 0 configuration(s)
- Published / Modified
- 2026-06-29 / 2026-07-07
NVD description (verbatim)
A vulnerability was found in llvm llvm-project up to 22.1.6. This affects the function llvm::StringMap::insert in the library /lib/IR/ValueSymbolTable.cpp of the component ValueSymbolTable Module. The manipulation results in stack-based buffer overflow. Attacking locally is a requirement. The exploit has been made public and could be used. The presence of this vulnerability remains uncertain at this time. The LLVM project explains, that the reported behavior is outside its documented security scope and therefore not considered a security vulnerability.
7 reference(s) · View on NVD →
SEC.co analysis · AI-assisted, reviewed against source
Technical summary
CVE-2026-13573 describes a stack-based buffer overflow in llvm::StringMap::insert, located in /lib/IR/ValueSymbolTable.cpp. The vulnerability stems from improper bounds checking when inserting values into the StringMap data structure. Exploitation requires local system access and appropriate privileges to call the affected code path. The CVSS 3.1 vector (CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:L) reflects a low base score of 3.3, with impact limited to availability. Related weakness classifications include CWE-119 (Improper Restriction of Operations within the Bounds of a Memory Buffer) and CWE-121 (Stack-based Buffer Overflow).
Business impact
Given the low CVSS score and local-only attack vector, direct business impact is limited. However, if LLVM is embedded in your build toolchain or development infrastructure, a malicious local actor could cause denial of service by crashing the compiler. This could disrupt build pipelines. The more significant concern is reputational: public exploit code exists, making this a visible security topic despite LLVM's disagreement on its scope classification.
Affected systems
LLVM versions up to 22.1.6 are in scope. No specific downstream products were identified in the vulnerability record. Check your LLVM installation version and verify whether you use LLVM for compilation, static analysis, or JIT execution in your environment. Organizations with isolated development environments or air-gapped build systems face lower risk.
Exploitability
Exploitation requires local access and sufficient privileges (low-level user account permission). An attacker must trigger the StringMap::insert function with specially crafted input. Exploit code is publicly available, lowering the bar for practical attacks but not eliminating the local-access requirement. The LLVM maintainers' statement that this falls outside their security scope suggests debate exists over whether real-world conditions trigger the flaw in normal usage.
Remediation
Upgrade LLVM beyond version 22.1.6 if a patched release is available. Consult the LLVM release notes and security advisories to confirm the version that addresses this issue. Verify the patch against the official LLVM project repository. If upgrading is not feasible in the short term, restrict local access to systems where LLVM is compiled or executed, and monitor for unusual compiler crashes or build failures.
Patch guidance
Check the LLVM project's official release page and commit history to identify the first version after 22.1.6 that resolves this issue. Apply the patch during a scheduled maintenance window, as LLVM upgrades may affect downstream dependent projects. Test the upgraded LLVM version against your build pipeline before full rollout. If you maintain a custom LLVM fork, backport the fix or rebase onto the patched upstream version.
Detection guidance
Monitor system logs for unexpected LLVM compiler crashes or segmentation faults, particularly in build processes initiated by untrusted local users. Implement access controls to restrict who can execute LLVM and submit compilation jobs. Use intrusion detection signatures that flag suspicious StringMap operations or buffer overrun attempts in LLVM processes. Code review and static analysis tools may catch unsafe input handling in LLVM integration code.
Why prioritize this
Despite public exploit availability, this vulnerability scores low in severity (3.3 CVSS) due to its local-only attack vector, low-privilege requirement, and limited impact scope (denial of service only). Prioritize remediation for systems where LLVM runs untrusted workloads or where multiple users share build infrastructure. Organizations with well-segmented development networks and strong access controls can defer this patch to a regular update cycle.
Risk score, explained
The CVSS 3.1 score of 3.3 reflects a low-severity vulnerability because: (1) Attack Vector is Local, requiring physical or logical access; (2) Attack Complexity is Low, but only for an attacker already present; (3) Privileges Required are Low, not None; (4) User Interaction is None; (5) the Scope is Unchanged; and (6) Impact is limited to Availability (denial of service), with no Confidentiality or Integrity impact. The public exploit code raises operational concern but does not alter the technical risk profile.
Frequently asked questions
Does LLVM consider this a security vulnerability?
No. The LLVM project has stated that the reported behavior falls outside its documented security scope and therefore does not classify it as a security vulnerability. This disagreement reflects a difference in perspective between the external researcher and the maintainers, though the defect exists in the code.
What LLVM versions are affected?
LLVM versions up to and including 22.1.6 are reportedly affected. Verify your version with 'llvm-config --version' and check release notes for patches beyond 22.1.6.
Can this vulnerability be exploited remotely?
No. Exploitation requires local system access and sufficient user privileges. Remote attackers cannot directly exploit this flaw.
Is there a workaround if I cannot immediately upgrade LLVM?
Restrict local user access to LLVM compilation services, use operating system-level protections (SELinux, AppArmor) to sandbox the compiler, and monitor for unexpected crashes. These measures reduce but do not eliminate risk.
This analysis is based on the CVE record published 2026-06-29 and last modified 2026-07-07. The LLVM project disputes the classification of this issue as a security vulnerability. No exploit code is provided herein. Patch availability and version numbers should be verified directly against official LLVM releases and security advisories. This page is for informational purposes and does not constitute legal or professional security advice. Organizations should conduct their own risk assessment based on their LLVM deployment and threat model. Source: NVD (public-domain), retrieved 2026-08-08. Analysis generated by SEC.co (claude-haiku-4-5).
Related vulnerabilities
- CVE-2026-10528LOWOrthanc DICOM Server Stack Buffer Overflow – Patch Guidance
- CVE-2026-14789LOWStack Buffer Overflow in Radare2 Memory Dump Parser
- CVE-2026-10062HIGHTRENDnet TEW-432BRP Stack Overflow – EOL Hardware Risk
- CVE-2026-10063HIGHTRENDnet TEW-432BRP Stack Overflow – End-of-Life Router Vulnerability
- CVE-2026-10064MEDIUMTRENDnet TEW-432BRP Stack Overflow – Unpatched EOL Router Vulnerability
- CVE-2026-10065HIGHShibby Tomato 1.28 Stack Buffer Overflow in tomatodata.cgi
- CVE-2026-10066HIGHShibby Tomato Stack Buffer Overflow in UPS Service (RCE)
- CVE-2026-10067HIGHShibby Tomato 1.28 Stack Buffer Overflow in multimon.cgi