Home / Vulnerability Database / C or C++ : Dangerous pointer manipulation
C/C++

C or C++ : Dangerous pointer manipulation

Classification

Overview

Some arithmetic manipulations on pointers may be dangerous:

  1. Pointer arithmetic on a pointer to base class is dangerous - base and derived may have different sizes.
  2. Pointer arithmetic on non-array variables relies on memory layout, which is dangerous.
  3. Subtraction of two pointers that do not point to the same memory chunk may cause incorrect result.
CRITICAL

DerScanner Severity Score

Do you want to fix C or C++ : Dangerous pointer manipulation in your application?

See also

C/C++

C or C++ : Dead store

C/C++

C or C++ : Use after free

C/C++

C or C++ : va_list uninitialized