Weaknesses of type CWE-130

106 results

Inconsistência no tratamento de parâmetros de comprimento

Ocorre quando o código não valida ou trata adequadamente inconsistências entre o comprimento declarado de um buffer/string e seu tamanho real. Um atacante explora essa discrepância para causar leitura ou escrita fora dos limites, levando a vazamento de dados, corrupção de memória ou execução de código.

Example

Uma função recebe uma string com um parâmetro 'length' que não corresponde ao tamanho real do buffer. Se o código copia 'length' bytes sem verificar se o buffer realmente possui esse tamanho, um memcpy() ou strcpy() escreve além do limite alocado, ou lê dados inválidos de memória adjacente.

How to mitigate

Sempre validar que o parâmetro de comprimento é coerente com o tamanho real do buffer antes de operações de cópia ou leitura. Use funções seguras (strncpy, memcpy_s) e implemente checks explícitos: se length > buffer_size, rejeitar ou truncar. Ferramentas de análise estática ajudam a detectar esse padrão.

CVE-2025-14847HIGHZlib compressed protocol header length confusion may allow memory readEPSS 83.0%KEVCVE-2024-39614HIGHAn issue was discovered in Django 5.0 before 5.0.7 and 4.2 before 4.2.14. get_supported_language_variant() was subject to a potential denialEPSS 28.6%CVE-2021-36090Apache Commons Compress 1.0 to 1.20 denial of service vulnerabilityEPSS 12.9%CVE-2021-35516Apache Commons Compress 1.6 to 1.20 denial of service vulnerabilityEPSS 12.4%CVE-2021-35517Apache Commons Compress 1.1 to 1.20 denial of service vulnerabilityEPSS 10.6%CVE-2019-3862HIGHAn out of bounds read flaw was discovered in libssh2 before 1.8.1 in the way SSH_MSG_CHANNEL_REQUEST packets with an exit status message andEPSS 8.1%CVE-2021-20588HIGHImproper Handling of Length Parameter Inconsistency vulnerability in Mitsubishi Electric FA Engineering Software (CPU Module Logging ConfiguEPSS 6.9%CVE-2024-20685MEDIUMAzure Private 5G Core Denial of Service VulnerabilityEPSS 5.5%CVE-2020-8927MEDIUMBuffer overflow in Brotli libraryEPSS 3.2%CVE-2021-20610HIGHImproper Handling of Length Parameter Inconsistency vulnerability in Mitsubishi Electric MELSEC iQ-R Series R00/01/02CPU, MELSEC iQ-R SeriesEPSS 3.1%CVE-2021-36374Apache Ant ZIP, and ZIP based, archive denial of service vulerabilityEPSS 2.6%CVE-2021-36373Apache Ant TAR archive denial of service vulnerabilityEPSS 2.5%CVE-2021-38445HIGHOCI OpenDDS Secure Improper Handling of Length Parameter InconsistencyEPSS 2.5%CVE-2021-43666HIGHA Denial of Service vulnerability exists in mbed TLS 3.0.0 and earlier in the mbedtls_pkcs12_derivation function when an input password's leEPSS 2.2%CVE-2022-3272MEDIUMImproper Handling of Length Parameter Inconsistency in ikus060/rdiffwebEPSS 1.5%CVE-2022-24666A program using swift-nio-http2 is vulnerable to a denial of service attack, caused by a network peer sending a specially crafted HTTP/2 fraEPSS 1.4%CVE-2019-0055HIGHJunos OS: SRX Series: An attacker may cause flowd to crash by sending certain valid SIP traffic to a device with SIP ALG enabled.EPSS 1.3%CVE-2022-0618A program using swift-nio-http2 is vulnerable to a denial of service attack, caused by a network peer sending a specially crafted HTTP/2 fraEPSS 1.3%CVE-2024-38011HIGHSecure Boot Security Feature Bypass VulnerabilityEPSS 1.3%CVE-2026-33846HIGHGnutls: gnutls: denial of service via heap buffer overflow in dtls handshake fragment reassemblyEPSS 1.3%