CWE-453: Insecure Default Variable Initialization
The product, by default, initializes an internal variable with an insecure or less secure value than is possible.
Browse cwe weaknesses with official CWE context and Glexia analysis.
Search And Filters
Showing 50 of 969 CWE records · Page 9 of 20.
The product, by default, initializes an internal variable with an insecure or less secure value than is possible.
The product initializes critical internal variables or data stores using inputs that can be modified by untrusted actors.
The product does not exit or otherwise modify its operation when security-relevant errors occur during initialization, such as when a configuration file has a format error or a hardware security module (HSM) cannot be activated, which can cause the product to execute in a less secure fashion than intended by the administrator.
The product does not initialize critical variables, which causes the execution environment to use unexpected values.
The code uses a variable that has not been initialized, leading to unpredictable or unintended results.
This weakness has been deprecated because its name and description did not match. The description duplicated CWE-454, while the name suggested a more abstract initialization problem. Please refer to CWE-665 for the more abstract problem.
The product does not properly "clean up" and remove temporary or supporting resources after they have been used.
The product does not clean up its state or incorrectly cleans up its state when an exception is thrown, leading to unexpected state or control flow.
Duplicate keys in associative lists can lead to non-unique keys being mistaken for an error.
The accidental deletion of a data-structure sentinel can cause serious programming logic problems.
The accidental addition of a data-structure sentinel can cause serious programming logic problems.
A function can return a pointer to memory that is outside of the buffer that the pointer is expected to reference.
The code calls sizeof() on a pointer type, which can be an incorrect calculation if the programmer intended to determine the size of the data that is being pointed to.
In C and C++, one may often accidentally refer to the wrong memory due to the semantics of when math operations are implicitly scaled.
The product subtracts one pointer from another in order to determine size, but this calculation can be incorrect if the pointers do not exist in the same memory chunk.
The product uses external input with reflection to select which classes or code to use, but it does not sufficiently prevent the input from selecting improper classes or code.
The product does not properly protect an assumed-immutable element from being modified by an attacker.
The web application does not sufficiently verify inputs that are assumed to be immutable but are actually externally controllable, such as hidden form fields.
A PHP application does not properly protect against the modification of variables from external sources, such as query parameters or cookies. This can expose the application to numerous weaknesses that would not exist otherwise.
The code uses a function that has inconsistent implementations across operating systems and versions.
The behavior of this function is undefined unless its control parameter is set to a specific value.
The product dereferences a pointer that it expects to be valid but is NULL.
The code uses deprecated or obsolete functions, which suggests that the code has not been actively reviewed or maintained.
The code does not have a default case in an expression with multiple conditions, such as a switch statement.
The product defines a signal handler that calls a non-reentrant function.
The product accidentally uses the wrong operator, which changes the logic in security-relevant ways.
The code uses an operator for assignment when the intention was to perform a comparison.
The code uses an operator for comparison when the intention was to perform an assignment.
The code does not explicitly delimit a block that is intended to contain 2 or more statements, creating a logic error.
The product omits a break statement within a switch or similar construct, causing code associated with multiple conditions to execute. This can cause problems when the programmer only intended to execute code associated with one condition.
The product compares classes by name, which can cause it to use the wrong class when multiple classes can have the same name.
Java packages are not inherently closed; therefore, relying on them for code security is not a good practice.
The product does not sufficiently enforce boundaries between the states of different sessions, causing data to be provided to, or used by, the wrong session.
The product is released with debugging code still enabled or active.
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.
Inner classes are translated into classes that are accessible at package scope and may expose code that the programmer intended to keep private to attackers.
The product has a critical public variable that is not final, which allows the variable to be modified to contain unexpected values.
The product downloads source code or an executable from a remote location and executes the code without sufficiently verifying the origin and integrity of the code.
The product has a method that is declared public, but returns a reference to a private data structure, which could then be modified in unexpected ways.
Assigning public data to a private array is equivalent to giving public access to the array.
The product does not properly prevent sensitive system-level information from being accessed by unauthorized actors who do not have the same level of access to the underlying system as the product does.
The code contains a class with sensitive data, but the class is cloneable. The data can then be accessed by cloning the class.
The code contains a class with sensitive data, but the class does not explicitly deny serialization. The data can be accessed by serializing the class through another class.
An object contains a public static field that is not marked final, which might allow it to be modified in unexpected ways.
The product mixes trusted and untrusted data in the same data structure or structured message.
The product deserializes untrusted data without sufficiently ensuring that the resulting data will be valid.
The product contains code that appears to be malicious in nature.
The product appears to contain benign or useful functionality, but it also contains code that is hidden from normal operation that violates the intended security policy of the user or the system administrator.
Non-replicating malicious code only resides on the target system or product that is attacked; it does not attempt to spread to other systems.
Replicating malicious code, including viruses and worms, will attempt to attack other systems once it has successfully compromised the target system or the product.