| Impact | Details |
|---|---|
|
Unexpected State; Varies by Context |
Scope: Integrity, Other |
| Phase(s) | Mitigation |
|---|---|
|
Implementation |
Make the cloneable() method final.
|
| Nature | Type | ID | Name |
|---|---|---|---|
| ChildOf | Class Class - a weakness that is described in a very abstract fashion, typically independent of any specific language or technology. More specific than a Pillar Weakness, but more general than a Base Weakness. Class level weaknesses typically describe issues in terms of 1 or 2 of the following dimensions: behavior, property, and resource. | 668 | Exposure of Resource to Wrong Sphere |
| Phase | Note |
|---|---|
| Implementation |
Java (Undetermined Prevalence)
Example 1
In this example, a public class "BankAccount" implements the cloneable() method which declares "Object clone(string accountnumber)":
Example 2
In the example below, a clone() method is defined without being declared final.
| Nature | Type | ID | Name |
|---|---|---|---|
| MemberOf | CategoryCategory - a CWE entry that contains a set of other entries that share a common characteristic. | 485 | 7PK - Encapsulation |
| MemberOf | CategoryCategory - a CWE entry that contains a set of other entries that share a common characteristic. | 849 | The CERT Oracle Secure Coding Standard for Java (2011) Chapter 6 - Object Orientation (OBJ) |
| MemberOf | CategoryCategory - a CWE entry that contains a set of other entries that share a common characteristic. | 1002 | SFP Secondary Cluster: Unexpected Entry Points |
| MemberOf | CategoryCategory - a CWE entry that contains a set of other entries that share a common characteristic. | 1139 | SEI CERT Oracle Secure Coding Standard for Java - Guidelines 05. Object Orientation (OBJ) |
| MemberOf | CategoryCategory - a CWE entry that contains a set of other entries that share a common characteristic. | 1403 | Comprehensive Categorization: Exposed Resource |
Rationale
This CWE entry is at the Variant level of abstraction, which is a preferred level of abstraction for mapping to the root causes of vulnerabilities.Comments
Carefully read both the name and description to ensure that this mapping is an appropriate fit. Do not try to 'force' a mapping to a lower-level Base/Variant simply to comply with this preferred level of abstraction.| Mapped Taxonomy Name | Node ID | Fit | Mapped Node Name |
|---|---|---|---|
| 7 Pernicious Kingdoms | Mobile Code: Object Hijack | ||
| The CERT Oracle Secure Coding Standard for Java (2011) | OBJ07-J | Sensitive classes must not let themselves be copied | |
| Software Fault Patterns | SFP28 | Unexpected access points |
| Submissions | |||
|---|---|---|---|
| Submission Date | Submitter | Organization | |
|
2006年07月19日
(CWE Draft 3, 2006年07月19日) |
7 Pernicious Kingdoms | ||
| Modifications | |||
| Modification Date | Modifier | Organization | |
| 2023年06月29日 | CWE Content Team | MITRE | |
| updated Mapping_Notes | |||
| 2023年04月27日 | CWE Content Team | MITRE | |
| updated Relationships | |||
| 2020年02月24日 | CWE Content Team | MITRE | |
| updated References, Relationships | |||
| 2019年01月03日 | CWE Content Team | MITRE | |
| updated Relationships, Taxonomy_Mappings | |||
| 2014年07月30日 | CWE Content Team | MITRE | |
| updated Relationships, Taxonomy_Mappings | |||
| 2012年10月30日 | CWE Content Team | MITRE | |
| updated Potential_Mitigations | |||
| 2012年05月11日 | CWE Content Team | MITRE | |
| updated Relationships, Taxonomy_Mappings | |||
| 2011年06月27日 | CWE Content Team | MITRE | |
| updated Common_Consequences | |||
| 2011年06月01日 | CWE Content Team | MITRE | |
| updated Common_Consequences, Relationships, Taxonomy_Mappings | |||
| 2009年07月27日 | CWE Content Team | MITRE | |
| updated Demonstrative_Examples | |||
| 2009年05月27日 | CWE Content Team | MITRE | |
| updated Name | |||
| 2008年09月08日 | CWE Content Team | MITRE | |
| updated Relationships, References, Taxonomy_Mappings | |||
| 2008年07月01日 | Eric Dalci | Cigital | |
| updated References, Demonstrative_Example, Potential_Mitigations, Time_of_Introduction | |||
| 2008年07月01日 | Sean Eidemiller | Cigital | |
| added/updated demonstrative examples | |||
| Previous Entry Names | |||
| Change Date | Previous Entry Name | ||
| 2008年04月11日 | Mobile Code: Object Hijack | ||
| 2009年05月27日 | Public cloneable() Method Without Final (aka 'Object Hijack') | ||
Use of the Common Weakness Enumeration (CWE™) and the associated references from this website are subject to the Terms of Use. CWE is sponsored by the U.S. Department of Homeland Security (DHS) Cybersecurity and Infrastructure Security Agency (CISA) and managed by the Homeland Security Systems Engineering and Development Institute (HSSEDI) which is operated by The MITRE Corporation (MITRE). Copyright © 2006–2025, The MITRE Corporation. CWE, CWSS, CWRAF, and the CWE logo are trademarks of The MITRE Corporation.