Skip to content
OpenAdvisories

Weakness (CWE)

CWE-491: Public cloneable() Method Without Final

Variant Draft

A class has a cloneable() method that is not declared final, which allows an object to be created without calling the constructor. This can cause the object to be in an unexpected state.

How to prevent it (1 mitigation)
  1. Implementation

    Make the cloneable() method final.

Source: MITRE CWE-491

0 results · Clear filters · Feed

Nothing found.