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 3,251 to 3,300 of 3,817
  1. The page number of an annotation is read twice without locking and JavaScript can change it between the check and the use.

    Seen in 1 report
  2. The page unload preventer was removed based only on remaining stroke data, ignoring cached page-object handles still held.

    Seen in 1 report
  3. The pair count is computed in 32-bit signed arithmetic, so a large endpoint count overflows and the initialisation loop is skipped, leaving link arrays at a sentinel value.

    Seen in 1 report
  4. The parameter extraction loop iterated all query strings without checking the destination array capacity.

    Seen in 1 report
  5. The parameter set cache was keyed only by identifier without layer namespacing, and the alpha-layer branch did not flush the current frame.

    Seen in 1 report
  6. The parent field of the timed event class was never initialised.

    Seen in 1 report
  7. The parent iframe's cache was not invalidated on child destruction because an early return skipped the update, and the lookup used an unchecked downcast.

    Seen in 1 report
  8. The parent process trusts two type fields from the child's IPC message without checking they are consistent, then downcasts based on one while the object was created from the other.

    Seen in 1 report
  9. The parent worker's shutdown is triggered by the child worker's termination, freeing the global scope in the same task that schedules a callback which later accesses it.

    Seen in 1 report
  10. The parent-side validator for the browser id field took a 32-bit reference while the field is 64-bit, so the generic permissive template was chosen and content-sourced changes were accepted.

    Seen in 1 report
  11. The parser accesses memory that has not been properly initialised.

    Seen in 1 report
  12. The parser advanced the destination pointer without reducing the remaining length when a label had zero length, so a later copy overflowed the heap.

    Seen in 1 report
  13. The parser allocates the format array based on expected tokens but does not initialise or validate every element when the format line is empty or invalid.

    Seen in 1 report
  14. The parser allows variable definitions after the header ends, letting the minimum hash ID change and causing an out-of-bounds lookup.

    Seen in 1 report
  15. The parser assumes a closing brace always follows an opening brace and sizes a memory move from the remaining string.

    Seen in 1 report
  16. The parser assumes a vector has an element when only a closing tag is present.

    Seen in 1 report
  17. The parser assumes an OLE object pointer exists at a fixed stack offset even when the initialisation routine was never called.

    Seen in 1 report
  18. The parser assumes the element data section has as many entries as the element section, which is not enforced.

    Seen in 1 report
  19. The parser context functions call a string length macro on the data argument without first verifying it is a Ruby String.

    Seen in 1 report
  20. The parser copied user-supplied data into a fixed-length heap buffer without checking its length.

    Seen in 1 report
  21. The parser copies data from CONTINUEFRT12 records into a heap buffer without checking the record length first.

    Seen in 1 report
  22. The parser copies user-supplied data into a stack buffer without checking its length.

    Seen in 1 report
  23. The parser dereferenced an object after freeing it because it did not validate the object's existence first.

    Seen in 1 report
  24. The parser did not check that the assertion consumer service URL was present and terminated before copying it into the response cookie.

    Seen in 1 report
  25. The parser did not check the type of user-supplied data before using it, so crafted input was treated as the wrong object type.

    Seen in 1 report
  26. The parser did not properly validate user-supplied data, leading to memory corruption.

    Seen in 1 report
  27. The parser did not validate that colour and rectangle-type entry counts matched the grid dimensions, so the recorder recalculated a larger count and read past the buffer.

    Seen in 1 report
  28. The parser did not validate that the object referenced by the associated file entry was of the expected file specification type.

    Seen in 1 report
  29. The parser does not account for an extra byte written when a delimiter is present, so the loop writes one byte past a 256-byte buffer.

    Seen in 1 report
  30. The parser does not check that a character follows a backslash, so a trailing backslash makes it read past the string terminator.

    Seen in 1 report
  31. The parser does not check that an object still exists before using it.

    Seen in 1 report
  32. The parser does not check that an object still exists before using it, leading to use-after-free.

    Seen in 1 report
  33. The parser does not check that enough bytes remain before reading a character at the current position.

    Seen in 1 report
  34. The parser does not check that the compressed frame header size is within the declared first partition size, causing an unsigned integer underflow.

    Seen in 1 report
  35. The parser does not enforce the baseline limit of 0 to 3 on the quantization table selector before passing it to the driver.

    Seen in 1 report
  36. The parser does not expect re-entrant JavaScript during a microtask checkpoint and keeps using its object after navigation frees it.

    Seen in 1 report
  37. The parser does not reload the descriptor count after a garbage collection triggered by error handling.

    Seen in 1 report
  38. The parser does not validate length or bounds before copying into a fixed-size buffer.

    Seen in 1 report
  39. The parser does not validate size or contents before writing to a buffer.

    Seen in 1 report
  40. The parser does not validate the length of user-supplied data before copying it into a fixed-length heap buffer.

    Seen in 1 report
  41. The parser does not validate the length of user-supplied data before writing it into a fixed-size buffer.

    Seen in 1 report
  42. The parser does not validate the length or structure of data before reading it.

    Seen in 1 report
  43. The parser does not validate the size or content of user data before copying it into a fixed-size buffer.

    Seen in 1 report
  44. The parser does not validate the size or content of user-supplied data before writing it to memory.

    Seen in 1 report
  45. The parser does not validate the size or content of user-supplied data before writing to a buffer.

    Seen in 1 report
  46. The parser does not validate the size or contents of user-supplied data before writing to a buffer.

    Seen in 1 report
  47. The parser does not validate the size or contents of user-supplied data before writing to a buffer.

    Seen in 1 report
  48. The parser does not validate the size or contents of user-supplied data before writing to a memory buffer.

    Seen in 1 report
  49. The parser does not validate the size or offset of user-supplied data before writing to a memory buffer.

    Seen in 1 report
  50. The parser does not validate the size or structure of data read from the file, leading to memory corruption.

    Seen in 1 report