CWE-341: Predictable from Observable State
CWE版本: 4.18
更新日期: 2025-09-09
弱点描述
A number or object is predictable based on observations that the attacker can make about the state of the system or network, such as time, process ID, etc.
常见后果
影响范围: Other
技术影响: Varies by Context
说明: This weakness could be exploited by an attacker in a number ways depending on the context. If a predictable number is used to generate IDs or keys that are used within protection mechanisms, then an attacker could gain unauthorized access to the system. If predictable filenames are used for storing sensitive information, then an attacker might gain access to the system and may be able to gain access to the information in the file.
潜在缓解措施
阶段: Implementation
描述: Increase the entropy used to seed a PRNG.
阶段: Architecture and Design Requirements
策略: Libraries or Frameworks
描述: Use products or modules that conform to FIPS 140-2 [REF-267] to avoid obvious entropy problems. Consult FIPS 140-2 Annex C ("Approved Random Number Generators").
阶段: Implementation
描述: Use a PRNG that periodically re-seeds itself using input from high-quality sources, such as hardware devices with high entropy. However, do not re-seed too frequently, or else the entropy source might block.
观察示例
参考: CVE-2002-0389
Mail server stores private mail messages with predictable filenames in a world-executable directory, which allows local users to read private mailing list archives.
参考: CVE-2001-1141
PRNG allows attackers to use the output of small PRNG requests to determine the internal state information, which could be used by attackers to predict future pseudo-random numbers.
参考: CVE-2000-0335
DNS resolver library uses predictable IDs, which allows a local attacker to spoof DNS query results.
参考: CVE-2005-1636
MFV. predictable filename and insecure permissions allows file modification to execute SQL queries.
引入模式
| 阶段 | 说明 |
|---|---|
| Architecture and Design | - |
| Implementation | REALIZATION: This weakness is caused during implementation of an architectural security tactic. |
适用平台
编程语言
分类映射
| 分类名称 | 条目ID | 条目名称 | 映射适配度 |
|---|---|---|---|
| PLOVER | - | Predictable from Observable State | - |