Skip to content

In-depth lesson · Memory corruption

Root causes

Every point the Memory corruption reports back under this heading, best-backed first, each with the reports it is seen in.

Back to the lesson 1 to 50 of 3,817
  1. An object is used without checking it still exists, leaving a dangling pointer.

    Seen in 116 reports
  2. A user-controlled value is dereferenced as a pointer without validating that it points to legitimate memory.

    Seen in 96 reports
  3. Objects are used after being freed because their existence is not checked before use.

    Seen in 67 reports
  4. The dominant root cause is missing or incorrect length and bounds checks before copying input into a heap or stack buffer.

    Seen in 67 reports
  5. Incoming data is written to a heap buffer without a correct size or bounds check.

    Seen in 60 reports
  6. Input sizes or lengths are not checked before data is copied into heap or stack buffers, causing overflows.

    Seen in 57 reports
  7. Missing bounds checks let parsers read or write past the end of an allocated buffer.

    Seen in 56 reports
  8. File parser bounds checks are missing: parsers trust length, size or offset fields in the file and copy or read without checking them against the destination buffer.

    Seen in 56 reports
  9. Memory is freed while still referenced, or freed twice, because object lifetime is not tracked across threads.

    Seen in 50 reports
  10. User-supplied lengths or sizes are trusted and copied into fixed-size buffers without a bounds check.

    Seen in 49 reports
  11. The code freed an object and later used it without checking that it still existed.

    Seen in 47 reports
  12. Scripting methods and properties operate on objects without checking that they still exist, so freed memory is reused.

    Seen in 46 reports
  13. File parsers trust size, length or offset values in the file without checking them against the destination or allocated buffer.

    Seen in 45 reports
  14. Incoming data copied into a heap buffer without a correct size or bounds check.

    Seen in 43 reports
  15. CAD and 3D file parsers repeatedly wrote or read past the end of allocated buffers because bounds checks were missing.

    Seen in 43 reports
  16. A user-controlled length is not checked before copying into a fixed-size heap or stack buffer.

    Seen in 42 reports
  17. Most Apple memory corruption reports trace to missing or insufficient bounds checks before writing or reading image, font, model or file system data.

    Seen in 39 reports
  18. A missing bounds check lets a read or write go past the end of an allocated buffer.

    Seen in 38 reports
  19. User-supplied data is copied into a fixed-length stack buffer without a length check first.

    Seen in 36 reports
  20. Generic mishandling of objects in memory in scripting engines, kernel components and libraries.

    Seen in 34 reports
  21. Size or index values from the input are trusted without checking them against the allocated buffer.

    Seen in 34 reports
  22. Code freed objects and then used them again without checking they still existed.

    Seen in 33 reports
  23. Use-after-free where memory is accessed after being released, often requiring a race condition.

    Seen in 33 reports
  24. User-supplied data was copied into fixed-length stack or heap buffers without checking its length first.

    Seen in 33 reports
  25. Image and document parsing lacks bounds checks before reading or writing user-supplied data.

    Seen in 32 reports
  26. Objects are freed while still referenced, so a race window lets an attacker reuse the freed memory.

    Seen in 32 reports
  27. Objects are used after being freed because existence is not checked before the operation.

    Seen in 32 reports
  28. Objects are freed but still referenced, giving use-after-free conditions often only reachable through a race.

    Seen in 32 reports
  29. A second root cause is memory lifetime management: objects freed while still referenced, producing use-after-free conditions.

    Seen in 31 reports
  30. The parser does not check that an object still exists before using it, leading to a use-after-free.

    Seen in 31 reports
  31. User-supplied data copied into a fixed stack buffer without a length check.

    Seen in 31 reports
  32. Lengths, sizes and offsets from the input are trusted without bounds checks, leading to reads and writes past allocated buffers.

    Seen in 30 reports
  33. Memory freed but still referenced, often only reachable by winning a race condition.

    Seen in 30 reports
  34. Objects are freed or closed but later used without checking they still exist.

    Seen in 30 reports
  35. Objects are used after being freed because existence is not checked before use.

    Seen in 30 reports
  36. File parsing trusts size, length or offset fields from the file without checking them against the allocated buffer.

    Seen in 30 reports
  37. The vulnerable window only opens when two threads race, so timing is central to exploitation.

    Seen in 30 reports
  38. Buffers are read past their end because the read length is not checked against the allocation.

    Seen in 29 reports
  39. Objects are freed while still referenced, often with a race window that lets an attacker influence the freed memory.

    Seen in 29 reports
  40. User-supplied data is used without validating its size or structure before memory operations.

    Seen in 29 reports
  41. Attribute values from parsed files were copied into fixed-size stack or heap buffers without a length check.

    Seen in 28 reports
  42. Code used or freed objects without checking they still existed, causing use-after-free and double free.

    Seen in 28 reports
  43. User-supplied lengths are copied into fixed-size buffers without checking them first.

    Seen in 28 reports
  44. Heap-based buffer overflow from missing or wrong length and size checks.

    Seen in 27 reports
  45. Objects are freed or invalidated but later dereferenced without checking they still exist, across services, parsers and drivers.

    Seen in 27 reports
  46. The parser uses an object after freeing it because it does not check the object still exists.

    Seen in 27 reports
  47. Objects are freed and then used again, often with a race window that makes the timing exploitable.

    Seen in 26 reports
  48. Size or offset values from user-supplied files are trusted without checking them against the real buffer length.

    Seen in 25 reports
  49. The parser trusts size or offset values in the file without checking them against the actual buffer, so it reads or writes beyond the allocated object.

    Seen in 25 reports
  50. A length field or data block from the file is copied into a fixed-size stack buffer without checking that it fits.

    Seen in 24 reports