VariantDraft

CWE-122Heap-based Buffer Overflow

Category: memory

Description

A heap overflow condition is a buffer overflow, where the buffer that can be overwritten is allocated in the heap portion of memory, generally meaning that the buffer was allocated using a routine such as malloc().

Common consequences· 3

  • Availability — DoS: Crash, Exit, or Restart, DoS: Resource Consumption (CPU), DoS: Resource Consumption (Memory)
    Buffer overflows generally lead to crashes. Other attacks leading to lack of availability are possible, including putting the program into an infinite loop.
  • Integrity / Confidentiality / Availability / Access Control — Execute Unauthorized Code or Commands, Bypass Protection Mechanism, Modify Memory
    Buffer overflows often can be used to execute arbitrary code, which is usually outside the scope of a program's implicit security policy. Besides important user data, heap-based overflows can be used to overwrite function pointers that may be living in memory, pointing it to the attacker's code. Even in applications that do not explicitly use function pointers, the run-time will usually leave many in memory. For example, object methods in C++ are generally implemented using function pointers. Even in C programs, there is often a global offset table used by the underlying runtime.
  • Integrity / Confidentiality / Availability / Access Control / Other — Execute Unauthorized Code or Commands, Bypass Protection Mechanism, Other
    When the consequence is arbitrary code execution, this can often be used to subvert any other security service.

Potential mitigations· 5

  • []Pre-design: Use a language or compiler that performs automatic bounds checking.
  • [Architecture and Design]Use an abstraction library to abstract away risky APIs. Not a complete solution.
  • [Operation, Build and Compilation]
  • [Operation, Build and Compilation]
  • [Implementation]Implement and perform bounds checking on input.

Related CAPEC attack patterns· 1

CAPEC-92

References

  1. https://cwe.mitre.org/data/definitions/122.html

Exploits (incoming)1

TypeTargetConfidenceTier
AttackPatternForced Integer Overflowcapec-92100%live

(incoming)149

TypeTargetConfidenceTier
VulnerabilityCVE-2025-0434cve-2025-04340%live
VulnerabilityCVE-2025-0611cve-2025-06110%live
VulnerabilityCVE-2025-0903cve-2025-09030%live
VulnerabilityCVE-2025-0999cve-2025-09990%live
VulnerabilityCVE-2025-10101cve-2025-101010%live
VulnerabilityCVE-2025-1049cve-2025-10490%live
VulnerabilityCVE-2025-10502cve-2025-105020%live
VulnerabilityCVE-2025-1051cve-2025-10510%live
VulnerabilityCVE-2025-1052cve-2025-10520%live
VulnerabilityCVE-2025-11205cve-2025-112050%live
VulnerabilityCVE-2025-11458cve-2025-114580%live
VulnerabilityCVE-2025-11778cve-2025-117780%live
VulnerabilityCVE-2025-11788cve-2025-117880%live
VulnerabilityCVE-2025-1426cve-2025-14260%live
VulnerabilityCVE-2025-14672cve-2025-146720%live
VulnerabilityCVE-2025-14673cve-2025-146730%live
VulnerabilityCVE-2025-15230cve-2025-152300%live
VulnerabilityCVE-2025-15233cve-2025-152330%live
VulnerabilityCVE-2025-15234cve-2025-152340%live
VulnerabilityCVE-2025-15247cve-2025-152470%live
VulnerabilityCVE-2025-15272cve-2025-152720%live
VulnerabilityCVE-2025-15274cve-2025-152740%live
VulnerabilityCVE-2025-15275cve-2025-152750%live
VulnerabilityCVE-2025-1538cve-2025-15380%live
VulnerabilityCVE-2025-1943cve-2025-19430%live
VulnerabilityCVE-2025-20260cve-2025-202600%live
VulnerabilityCVE-2025-20363cve-2025-203630%live
VulnerabilityCVE-2025-20672cve-2025-206720%live
VulnerabilityCVE-2025-20680cve-2025-206800%live
VulnerabilityCVE-2025-20685cve-2025-206850%live

Showing top 30 of 149 by confidence. Click any target to see the full neighbourhood.

Related by meaning· 6

Nearest entities by semantic similarity across the cs-graph corpus.

CWE
Stack-based Buffer Overflow
CWE
Return of Pointer Value Outside of Expected Range
CAPEC
Overflow Buffers
CWE
Free of Memory not on the Heap
CWE
Buffer Underwrite ('Buffer Underflow')
CWE
Access of Memory Location After End of Buffer
Sourced from MITRE CWE 4.20. Curated for EU compliance use cases by Adam Lundqvist, Founder at SQUR.