CWE-331: Insufficient Entropy

Base Draft Simple

CWE版本: 4.18

更新日期: 2025-09-09

弱点描述

The product uses an algorithm or scheme that produces insufficient entropy, leaving patterns or clusters of values that are more likely to occur than others.

常见后果

影响范围: Access Control Other

技术影响: Bypass Protection Mechanism Other

说明: An attacker could guess the random numbers generated and could gain unauthorized access to a system if the random numbers are used for authentication and authorization.

潜在缓解措施

阶段: Implementation

描述: Determine the necessary entropy to adequately provide for randomness and predictability. This can be achieved by increasing the number of bits of objects such as keys and seeds.

观察示例

参考: CVE-2001-0950

Insufficiently random data used to generate session tokens using C rand(). Also, for certificate/key generation, uses a source that does not block when entropy is low.

参考: CVE-2008-2108

Chain: insufficient precision (CWE-1339) in random-number generator causes some zero bits to be reliably generated, reducing the amount of entropy (CWE-331)

引入模式

阶段 说明
Architecture and Design -
Implementation REALIZATION: This weakness is caused during implementation of an architectural security tactic.

适用平台

编程语言
Not Language-Specific (Undetermined)

分类映射

分类名称 条目ID 条目名称 映射适配度
PLOVER - Insufficient Entropy -
WASC 11 Brute Force -
CERT C Secure Coding MSC32-C Properly seed pseudorandom number generators Exact
关键信息

CWE ID: CWE-331

抽象级别: Base

结构: Simple

状态: Draft

相关弱点
相关攻击模式
CAPEC-59