Glossary
Heap
The region of memory used for dynamic allocations (malloc/new), managed by the runtime allocator rather than the CPU automatically.
The heap is the area of memory from which a program requests variable-sized allocations at runtime using functions like malloc, new, or VirtualAlloc. Unlike the stack, the heap is not automatically reclaimed when a function returns — the programmer (or garbage collector) must free it explicitly. Heap allocator metadata (chunk headers, free-list pointers) is stored inline with user data, making heap corruption bugs such as use-after-free and heap overflows common targets for exploitation. Understanding allocator internals (e.g., ptmalloc, jemalloc) is essential for heap exploitation research.