|
Status: Draft Weakness ID: 607 (Weakness Variant)Description Summary A public or protected static final field references a mutable object, which allows the object to be changed by malicious code, or accidentally from another package Potential Mitigations Protect mutable objects by making them private. Restrict access to the getter and setter as well. Demonstrative Examples Here, an array (which is inherently mutable) is labeled public static final. Java Example: public static final String[] USER_ROLES;
Relationships
Taxonomy Mappings
Applicable Platforms Languages Java Time of Introduction ImplementationContent History Submissions Anonymous Tool Vendor (under NDA). (Externally Mined) Modifications Sean Eidemiller. Cigital. 2008-07-01. (External) added/updated demonstrative examples Eric Dalci. Cigital. 2008-07-01. (External) updated Potential_Mitigations, Time_of_Introduction CWE Content Team. MITRE. 2008-09-08. (Internal) updated Relationships, Taxonomy_Mappings |
|
|
|||