Scope | Impact | Likelihood |
---|---|---|
Confidentiality Other | Other Note: When a protection mechanism relies on random values to restrict access to a sensitive resource, such as a session ID or a seed for generating a cryptographic key, then the resource being protected could be accessed by guessing the ID or key. | |
Access Control Other | Bypass Protection Mechanism, Other Note: If product relies on unique, unguessable IDs to identify a resource, an attacker might be able to guess an ID for a resource that is owned by another user. The attacker could then read the resource, or pre-create a resource with the same ID to prevent the legitimate program from properly sending the resource to the intended user. For example, a product might maintain session information in a file whose name is based on a username. An attacker could pre-create this file for a victim user, then set the permissions so that the application cannot generate the session for the victim, preventing the victim from using the application. | |
Access Control | Bypass Protection Mechanism, Gain Privileges or Assume Identity Note: When an authorization or authentication mechanism relies on random values to restrict access to restricted functionality, such as a session ID or a seed for generating a cryptographic key, then an attacker may access the restricted functionality by guessing the ID or key. |
References | Description |
---|---|
CVE-2021-3692 | PHP framework uses mt_rand() function (Marsenne Twister) when generating tokens |
CVE-2020-7010 | Cloud application on Kubernetes generates passwords using a weak random number generator based on deployment time. |
CVE-2009-3278 | Crypto product uses rand() library function to generate a recovery key, making it easier to conduct brute force attacks. |
CVE-2009-3238 | Random number generator can repeatedly generate the same value. |
CVE-2009-2367 | Web application generates predictable session IDs, allowing session hijacking. |
CVE-2009-2158 | Password recovery utility generates a relatively small number of random passwords, simplifying brute force attacks. |
CVE-2009-0255 | Cryptographic key created with a seed based on the system time. |
CVE-2008-5162 | Kernel function does not have a good entropy source just after boot. |
CVE-2008-4905 | Blogging software uses a hard-coded salt when calculating a password hash. |
CVE-2008-4929 | Bulletin board application uses insufficiently random names for uploaded files, allowing other users to access private files. |
CVE-2008-3612 | Handheld device uses predictable TCP sequence numbers, allowing spoofing or hijacking of TCP connections. |
CVE-2008-2433 | Web management console generates session IDs based on the login time, making it easier to conduct session hijacking. |
CVE-2008-0166 | SSL library uses a weak random number generator that only generates 65,536 unique keys. |
CVE-2008-2108 | Chain: insufficient precision causes extra zero bits to be assigned, reducing entropy for an API function that generates random numbers. |
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) |
CVE-2008-2020 | CAPTCHA implementation does not produce enough different images, allowing bypass using a database of all possible checksums. |
CVE-2008-0087 | DNS client uses predictable DNS transaction IDs, allowing DNS spoofing. |
CVE-2008-0141 | Application generates passwords that are based on the time of day. |
Use a well-vetted algorithm that is currently considered to be strong by experts in the field, and select well-tested implementations with adequate length seeds.
In general, if a pseudo-random number generator is not advertised as being cryptographically secure, then it is probably a statistical PRNG and should not be used in security-sensitive contexts.
Pseudo-random number generators can produce predictable numbers if the generator is known and the seed can be guessed. A 256-bit seed is a good starting point for producing a "random enough" number.
Use monitoring tools that examine the software's process as it interacts with the operating system and the network. This technique is useful in cases when source code is unavailable, if the software was not developed by you, or if you want to verify that the build phase did not introduce any new weaknesses. Examples include debuggers that directly attach to the running process; system-call tracing utilities such as truss (Solaris) and strace (Linux); system activity monitors such as FileMon, RegMon, Process Monitor, and other Sysinternals utilities (Windows); and sniffers and protocol analyzers that monitor network traffic.
Attach the monitor to the process and look for library functions that indicate when randomness is being used. Run the process multiple times to see if the seed changes. Look for accesses of devices or equivalent resources that are commonly used for strong (or weak) randomness, such as /dev/urandom on Linux. Look for library or system calls that access predictable information such as process IDs and system time.
According to SOAR, the following detection techniques may be useful:
According to SOAR, the following detection techniques may be useful:
According to SOAR, the following detection techniques may be useful:
According to SOAR, the following detection techniques may be useful:
According to SOAR, the following detection techniques may be useful:
According to SOAR, the following detection techniques may be useful:
CAPEC-ID | Attack Pattern Name |
---|---|
CAPEC-112 | Brute Force In this attack, some asset (information, functionality, identity, etc.) is protected by a finite secret value. The attacker attempts to gain access to this asset by using trial-and-error to exhaustively explore all the possible secret values in the hope of finding the secret (or a value that is functionally equivalent) that will unlock the asset. |
CAPEC-485 | Signature Spoofing by Key Recreation An attacker obtains an authoritative or reputable signer's private signature key by exploiting a cryptographic weakness in the signature algorithm or pseudorandom number generation and then uses this key to forge signatures from the original signer to mislead a victim into performing actions that benefit the attacker. |
CAPEC-59 | Session Credential Falsification through Prediction This attack targets predictable session ID in order to gain privileges. The attacker can predict the session ID used during a transaction to perform spoofing and session hijacking. |
Name | Organization | Date | Date release | Version |
---|---|---|---|---|
PLOVER | Draft 3 |
Name | Organization | Date | Comment |
---|---|---|---|
Eric Dalci | Cigital | updated Time_of_Introduction | |
CWE Content Team | MITRE | updated Background_Details, Relationships, Other_Notes, Relationship_Notes, Taxonomy_Mappings, Weakness_Ordinalities | |
CWE Content Team | MITRE | updated Relationships, Taxonomy_Mappings | |
CWE Content Team | MITRE | updated Description, Likelihood_of_Exploit, Other_Notes, Potential_Mitigations, Relationships | |
CWE Content Team | MITRE | updated Potential_Mitigations | |
CWE Content Team | MITRE | updated Demonstrative_Examples, Related_Attack_Patterns | |
CWE Content Team | MITRE | updated Applicable_Platforms, Common_Consequences, Description, Observed_Examples, Potential_Mitigations, Time_of_Introduction | |
CWE Content Team | MITRE | updated References, Relationships, Taxonomy_Mappings | |
CWE Content Team | MITRE | updated Related_Attack_Patterns | |
CWE Content Team | MITRE | updated Detection_Factors, Potential_Mitigations | |
CWE Content Team | MITRE | updated Demonstrative_Examples | |
CWE Content Team | MITRE | updated Common_Consequences, Relationships, Taxonomy_Mappings | |
CWE Content Team | MITRE | updated Relationships | |
CWE Content Team | MITRE | updated Potential_Mitigations, References, Relationships, Taxonomy_Mappings | |
CWE Content Team | MITRE | updated Demonstrative_Examples, Observed_Examples, References, Relationships | |
CWE Content Team | MITRE | updated Related_Attack_Patterns | |
CWE Content Team | MITRE | updated Related_Attack_Patterns | |
CWE Content Team | MITRE | updated Detection_Factors | |
CWE Content Team | MITRE | updated Relationships | |
CWE Content Team | MITRE | updated Functional_Areas, Likelihood_of_Exploit, Modes_of_Introduction, References, Relationships, Taxonomy_Mappings | |
CWE Content Team | MITRE | updated References | |
CWE Content Team | MITRE | updated Relationships, Taxonomy_Mappings | |
CWE Content Team | MITRE | updated Relationships | |
CWE Content Team | MITRE | updated Applicable_Platforms, Description, Relationships | |
CWE Content Team | MITRE | updated Maintenance_Notes, Relationships | |
CWE Content Team | MITRE | updated Demonstrative_Examples, Maintenance_Notes, Observed_Examples | |
CWE Content Team | MITRE | updated Relationships | |
CWE Content Team | MITRE | updated Observed_Examples, Relationships | |
CWE Content Team | MITRE | updated Common_Consequences, Description | |
CWE Content Team | MITRE | updated References, Relationships | |
CWE Content Team | MITRE | updated Mapping_Notes, Relationships | |
CWE Content Team | MITRE | updated Observed_Examples | |
CWE Content Team | MITRE | updated Mapping_Notes |