Fallos del tipo CWE-338

154 resultados

Uso de gerador de números pseudoaleatórios criptograficamente fraco

A aplicação utiliza funções de geração de números aleatórios (como Math.random(), rand() ou similar) que não são adequadas para fins criptográficos, permitindo que um atacante preveja ou reproduza os valores gerados. Isso compromete a segurança de operações sensíveis como geração de tokens, chaves de sessão, nonces e valores criptográficos.

Ejemplo

Um servidor web gera tokens de autenticação usando Math.random() em JavaScript ou rand() em C. Um atacante observa alguns tokens válidos, consegue adivinhar o padrão ou seed do gerador e forja um token válido para sequestrar sessões de outros usuários.

Cómo mitigar

Utilize geradores de números aleatórios criptograficamente seguros: crypto.getRandomValues() em JavaScript/navegadores, SecureRandom em Java, secrets em Python, ou /dev/urandom em sistemas Unix. Nunca use funções de propósito geral (Math.random, rand) para operações criptográficas ou de segurança.

CVE-2025-2814MEDIUMCrypt::CBC versions between 1.21 and 3.05 for Perl may use insecure rand() function for cryptographic functionsEPSS 0.2%CVE-2026-34871MEDIUMAn issue was discovered in Mbed TLS before 3.6.6 and 4.x before 4.1.0 and TF-PSA-Crypto before 1.1.0. There is a Predictable Seed in a PseudEPSS 0.2%CVE-2025-1860HIGHData::Entropy for Perl uses insecure rand() function for cryptographic functionsEPSS 0.2%CVE-2025-26379HIGHJohnson Controls IQ Panels2, 2+, IQHub, IQPanel 4, PowerG use of Cryptographically Weak Pseudo-Random Number GeneratorEPSS 0.2%CVE-2026-74887MEDIUMopenssl_encrypt before 1.4.0 Insecure Random Import in PQC ModuleEPSS 0.2%CVE-2026-47882HIGHSpring Boot DevTools remote secret generated with a non-cryptographic PRNGEPSS 0.2%CVE-2026-6146MEDIUMAmazon::Credentials versions through 1.2.0 for Perl uses rand to generate encryption keysEPSS 0.2%CVE-2026-40514HIGHSmarterTools SmarterMail < Build 9610 Cryptographic Weakness via Weak RNGEPSS 0.2%CVE-2024-45723HIGHgoTenna Pro ATAK Plugin Use of Cryptographically Weak Pseudo-Random Number GeneratorEPSS 0.1%CVE-2023-31305LOWGeneration of weak and predictable Initialization Vector (IV) in PMFW (Power Management Firmware) may allow an attacker with privileges to rEPSS 0.1%CVE-2025-41731HIGHJumo: Insufficient entropy in PRNG may lead to root accessEPSS 0.1%CVE-2025-27552MEDIUMDBIx::Class::EncodedColumn until 0.00032 for Perl uses insecure rand() function for salting password hashes in Crypt/Eksblowfish/Bcrypt.pmEPSS 0.1%CVE-2025-27551MEDIUMDBIx::Class::EncodedColumn until 0.00032 for Perl uses insecure rand() function for salting password hashes in Digest.pmEPSS 0.1%CVE-2026-11347HIGHHardcoded Cryptographic Keys and Weak IV Generation in linqiEPSS 0.1%