CWE-496 · Słabość
Public Data Assigned to Private Array-Typed Field
- Abstrakcja
- Wariant
- Status
- Niekompletny
- Dodano
- 19 lipca 2006
- Ostatnia zmiana
- 11 grudnia 2025
Opis
Assigning public data to a private array is equivalent to giving public access to the array.
Skutki
Integrity
Modify Application Data
The contents of the array can be modified from outside the intended scope.
Zapobieganie
Implementation
Do not allow objects to modify private members of a class.
Słabość nadrzędna
Kiedy powstaje
- Implementation
Dotyczy
Object-Oriented, C, C++, Java, C#
Źródła
- Seven Pernicious Kingdoms: A Taxonomy of Software Security Errors — Katrina Tsipenyuk, Brian Chess, Gary McGraw, NIST, 2005
Wpis z katalogu CWE 4.20.