CWE-908: Use of Uninitialized Resource

What is CWE-908?

CWE-908 is Use of Uninitialized Resource. The flaw arises when the product uses or accesses a resource that has not been initialized. The database currently holds 135 vulnerabilities mapped to CWE-908 and 1 of them are in the CISA Known Exploited Vulnerabilities catalog.

The analysis could not be completed. Please try again.

OWASP Top 10 Rank-
Related CVES (365 days)135
AbstractionBase
Likelihood of exploitMedium

Vulnerabilities mapped to CWE-908

135 vulnerabilities382% increase year over year

Vulnerabilities in CISA KEV for CWE-908

1 vulnerabilities

Official definition

ByMitre CWE

The product uses or accesses a resource that has not been initialized.

When a resource has not been properly initialized, the product may behave unexpectedly. This may lead to a crash or invalid memory access, but the consequences vary depending on the type of resource and how it is used within the product.

Characteristics

Modes of introduction

  • Implementation

Common consequences

ImpactScopeExplanation
Read Memory, Read Application DataConfidentialityWhen reusing a resource such as memory or a program variable, the original contents of that resource may not be cleared before it is sent to an untrusted party.
DoS: Crash, Exit, or RestartAvailabilityThe uninitialized resource may contain values that cause program flow to change in ways that the programmer did not intend.

Risk mitigations

  1. ImplementationExplicitly initialize the resource before use. If this is performed through an API function or standard procedure, follow all required steps.
  2. ImplementationPay close attention to complex conditionals that affect initialization, since some branches might not perform the initialization.
  3. ImplementationAvoid race conditions (CWE-362) during initialization routines.
  4. Build and CompilationRun or compile the product with settings that generate warnings about uninitialized variables or data.

Detection methods

MethodApproachEffectiveness
Automated Static AnalysisAutomated 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 searching for potentially-vulnerable patterns that connect "sources" (origins of input) with "sinks" (destinations where the data interacts with external components, a lower layer such as the OS, etc.)High

Representative vulnerabilities

Below are representative vulnerabilities related to this CWE, prioritized by severity.

Sources (2)

CWE™ Program, operated by The MITRE Corporation. Copyright © 2006–2026, The MITRE Corporation. The MITRE Corporation hereby grants you a non-exclusive, royalty-free license to use CWE for research, development, and commercial purposes. CWE Terms of Use.

Learn more

Run an in-depth assessment with complete web risk management

CyStack VulnScan continuously discovers assets, validates vulnerabilities, and helps security teams prioritize remediation across the organization.