CWE-1285: Improper Validation of Specified Index, Position, or Offset in Input

54 CVEs have CWE-1285 as their primary weakness. 0 of them are in the CISA KEV catalog. The highest EPSS score among them is 6.083%.

The product receives input that is expected to specify an index, position, or offset into an indexable resource such as a buffer or file, but it does not validate or incorrectly validates that the specified index/position/offset has the required properties.

Often, indexable resources such as memory buffers or files can be accessed using a specific position, index, or offset, such as an index for an array or a position for a file. When untrusted input is not properly validated before it is used as an index, attackers could access (or attempt to access) unauthorized portions of these resources. This could be used to cause buffer overflows, excessive resource allocation, or trigger unexpected failures.

Child of CWE-20: Improper Input Validation

Mitigations

Observed examples

Get more CVE data from the API.

Free without a key or signup. Pro adds monitoring and higher limits: pricing.

Sources