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.
-
The driver used values taken directly from shader bytecode as indices or offsets into memory tables without validating them.
Seen in 5 reports
-
The padded-tail handler subtracted padding from an already-zero output length, underflowing it so the store mask became all-ones and wrote past the buffer.
Seen in 5 reports
-
The parser copies a user-controlled length of data into a fixed-size buffer without checking it fits.
Seen in 5 reports
-
The parser copies user-controlled data into a fixed-size stack buffer without checking the length.
Seen in 5 reports
-
The parser freed an object but later used it without checking it was still valid.
Seen in 5 reports
-
The parser treats one object type as another, causing type confusion and out-of-bounds access.
Seen in 5 reports
-
The parser trusts size or length values in the file and writes or reads without confirming they fit.
Seen in 5 reports
-
The parser trusts size or length values in the file without checking them against the allocated buffer.
Seen in 5 reports
-
The parsers trusted size, length or offset values from the file without checking them against the allocated buffer.
Seen in 5 reports
-
The PDF library fails to validate or manage objects in memory, leading to memory corruption.
Seen in 5 reports
-
The PDF parser does not validate a user-controlled value before using it as a pointer, causing an untrusted pointer dereference.
Seen in 5 reports
-
The same allocation freed more than once, with a race widening the window.
Seen in 5 reports
-
The size of user-supplied data is not validated before a buffer is allocated, so an integer overflow makes the allocation too small.
Seen in 5 reports
-
The software does not validate that an object exists before performing operations on it, leading to a use-after-free.
Seen in 5 reports
-
Type confusion, heap overflow and use after free in Ruby extension bindings.
Seen in 5 reports
-
Untrusted pointer dereference, null pointer dereference or type confusion.
Seen in 5 reports
-
User-mode supplied pointers dereferenced without validation.
Seen in 5 reports
-
User-supplied data length is not validated before copying into a fixed-size stack buffer.
Seen in 5 reports
-
User-supplied lengths are used in size calculations without overflow checks before allocation.
Seen in 5 reports
-
Values taken directly from image files are used as array indices, loop limits or copy lengths without validation against buffer bounds.
Seen in 5 reports
-
A caller-supplied value is used as a pointer without validating that it refers to legitimate memory.
Seen in 4 reports
-
A file-controlled count overflows when added to an existing count or in the allocation calculation, giving an undersized buffer.
Seen in 4 reports
-
A JavaScript call can free the widget object and the code then uses it without a check.
Seen in 4 reports
-
A memory location is used before it is initialised.
Seen in 4 reports
-
A missing check that an object is still valid before use causes use-after-free.
Seen in 4 reports
-
A null pointer is dereferenced when processing input.
Seen in 4 reports
-
A pointer supplied by a low-privileged caller is dereferenced without validating the address.
Seen in 4 reports
-
A pointer supplied or influenced by an attacker is dereferenced without validation.
Seen in 4 reports
-
A pointer to request-owned data is kept in worker-global state and an interrupted cleanup leaves it dangling.
Seen in 4 reports
-
A value from the file is used as an index into a lookup table without checking it is within bounds.
Seen in 4 reports
-
An integer overflow occurs before a buffer is allocated, so the allocation is too small for the data copied.
Seen in 4 reports
-
An object was freed during parsing and later dereferenced without an existence check.
Seen in 4 reports
-
Arithmetic on sizes or lengths is not checked, so values overflow or wrap around before being used for memory operations.
Seen in 4 reports
-
Attacker-controlled length fields trusted and copied into fixed-size buffers without checking the destination size.
Seen in 4 reports
-
Browser internal object lifetimes and array handling were mismanaged, causing corruption and double frees.
Seen in 4 reports
-
Browsers access objects in memory improperly, causing memory corruption.
Seen in 4 reports
-
Buffer size calculations used 32-bit arithmetic that could wrap before being assigned to a 64-bit variable.
Seen in 4 reports
-
Buffer sizes were computed from one attacker-controlled field while the write loop was driven by a different field, so the allocation did not match the amount written.
Seen in 4 reports
-
Calculated write offset plus size is not checked against the allocated buffer.
Seen in 4 reports
-
Code freed an object during parsing but later used it without checking it still existed.
Seen in 4 reports
-
Code treats an object of one type as another, causing type confusion.
Seen in 4 reports
-
Components misinterpret the type of an object supplied through script or file data.
Seen in 4 reports
-
Form handling frees a Doc object but keeps operating on it without checking it is still valid.
Seen in 4 reports
-
Hand-written assembly for the Base64 intrinsic miscalculated the output length for malformed final groups, producing a negative length and a wider write than the destination holds.
Seen in 4 reports
-
Header values are copied into fixed-length buffers without a length check.
Seen in 4 reports
-
Improper handling of objects in memory.
Seen in 4 reports
-
Incorrect memory lifetime handling leading to use-after-free in browser engines.
Seen in 4 reports
-
Input size is not checked before being copied into a heap buffer.
Seen in 4 reports
-
Integer overflow and unchecked sizes in document filter parsers.
Seen in 4 reports
-
Integer overflow or underflow in size calculations before a memory write.
Seen in 4 reports