Description
The number of possible random values is smaller than needed by the product, making it more susceptible to brute force attacks.
Potential Impact
Access Control, Other
Bypass Protection Mechanism, Other
Demonstrative Examples
<sun-web-app>
...<session-config>
<session-properties><property name="idLengthBytes" value="8"><description>The number of bytes in this web module's session ID.</description></property></session-properties>
</session-config>...
</sun-web-app>Mitigations & Prevention
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").
Real-World CVE Examples
| CVE ID | Description |
|---|---|
| CVE-2002-0583 | Product uses 5 alphanumeric characters for filenames of expense claim reports, stored under web root. |
| CVE-2002-0903 | Product uses small number of random numbers for a code to approve an action, and also uses predictable new user IDs, allowing attackers to hijack new accounts. |
| CVE-2003-1230 | SYN cookies implementation only uses 32-bit keys, making it easier to brute force ISN. |
| CVE-2004-0230 | Complex predictability / randomness (reduced space). |
Related Weaknesses
Taxonomy Mappings
- PLOVER: — Small Space of Random Values
Frequently Asked Questions
What is CWE-334?
CWE-334 (Small Space of Random Values) is a software weakness identified by MITRE's Common Weakness Enumeration. It is classified as a Base-level weakness. The number of possible random values is smaller than needed by the product, making it more susceptible to brute force attacks.
How can CWE-334 be exploited?
Attackers can exploit CWE-334 (Small Space of Random Values) to bypass protection mechanism, other. This weakness is typically introduced during the Architecture and Design, Implementation phase of software development.
How do I prevent CWE-334?
Key mitigations include: 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").
What is the severity of CWE-334?
CWE-334 is classified as a Base-level weakness (Medium abstraction). It has been observed in 4 real-world CVEs.