Description
The product initializes or sets a resource with a default that is intended to be changed by the product's installer, administrator, or maintainer, but the default is not secure.
Potential Impact
Other
Varies by Context
Demonstrative Examples
// $user and $pass automatically set from POST request
if (login_user($user,$pass)) {$authorized = true;}
...
if ($authorized) {generatePage();}$user = $_POST['user'];$pass = $_POST['pass'];$authorized = false;if (login_user($user,$pass)) {$authorized = true;}
...Detection Methods
- Automated Static Analysis — Automated static analysis, commonly referred to as Static Application Security Testing (SAST), can find some instances of this weakness by analyzing source code (or binary/compiled code) without having to execute it. Typically, this is done by building a model of data flow and control flow, then sea
Real-World CVE Examples
| CVE ID | Description |
|---|---|
| CVE-2022-36349 | insecure default variable initialization in BIOS firmware for a hardware board allows DoS |
| CVE-2022-42467 | A generic database browser interface has a default mode that exposes a web server to the network, allowing queries to the database. |
Related Weaknesses
Frequently Asked Questions
What is CWE-1188?
CWE-1188 (Initialization of a Resource with an Insecure Default) is a software weakness identified by MITRE's Common Weakness Enumeration. It is classified as a Base-level weakness. The product initializes or sets a resource with a default that is intended to be changed by the product's installer, administrator, or maintainer, but the default is not secure.
How can CWE-1188 be exploited?
Attackers can exploit CWE-1188 (Initialization of a Resource with an Insecure Default) to varies by context. This weakness is typically introduced during the Implementation, System Configuration phase of software development.
How do I prevent CWE-1188?
Follow secure coding practices, conduct code reviews, and use automated security testing tools (SAST/DAST) to detect this weakness early in the development lifecycle.
What is the severity of CWE-1188?
CWE-1188 is classified as a Base-level weakness (Medium abstraction). It has been observed in 2 real-world CVEs.