Fallos del tipo CWE-193

129 resultados

Erro de índice por um (Off-by-One)

Ocorre quando a lógica de um loop ou acesso a array usa um índice incorreto — geralmente começando em 0 quando deveria começar em 1, ou iterando até N quando deveria parar em N-1. O resultado é acesso a posições inválidas de memória, leitura/escrita fora dos limites do buffer, ou skip de um elemento legítimo, criando brechas de segurança e crashes.

Ejemplo

Um loop que processa 10 elementos de um array mas itera de 0 a 10 (incluindo 10) tenta acessar posição 10 que não existe; ou um validador que checa strings até tamanho N mas esquece o caractere final, deixando dados não validados. Ataques exploram isso para corrupção de heap, escape de sandbox ou leitura de memória sensível.

Cómo mitigar

Use iteradores de linguagem de alto nível (for-each, ranges) que abstraem índices; ao usar índices explícitos, teste sempre com boundary values (tamanho-1, tamanho, tamanho+1); aplique assertions e sanitização rigorosa em loops críticos; prefira bibliotecas que fazem bounds-checking automático.

CVE-2022-41916MEDIUMRead one byte past a buffer when normalizing UnicodeEPSS 1.0%CVE-2026-50497MEDIUMWindows Remote Desktop Protocol (RDP) Information Disclosure VulnerabilityEPSS 0.9%CVE-2024-38441CRITICALNetatalk before 3.2.1 has an off-by-one error and resultant heap-based buffer overflow because of setting ibuf[len] to '\0' in FPMapName in EPSS 0.9%CVE-2024-38440HIGHNetatalk before 3.2.1 has an off-by-one error, and resultant heap-based buffer overflow and segmentation violation, because of incorrectly uEPSS 0.9%CVE-2022-3872HIGHAn off-by-one read/write issue was found in the SDHCI device of QEMU. It occurs when reading/writing the Buffer Data Port Register in sdhci_EPSS 0.9%CVE-2021-4070MEDIUMOff-by-one Error in v2fly/v2ray-coreEPSS 0.9%CVE-2022-23400HIGHA stack-based buffer overflow vulnerability exists in the IGXMPXMLParser::parseDelimiter functionality of Accusoft ImageGear 19.10. A speciaEPSS 0.8%CVE-2021-44007—A vulnerability has been identified in JT2Go (All versions < V13.2.0.5), Teamcenter Visualization (All versions < V13.2.0.5). The Tiff_LoadeEPSS 0.8%CVE-2022-36354MEDIUMA heap out-of-bounds read vulnerability exists in the RLA format parser of OpenImageIO master-branch-9aeece7a and v2.3.19.0. More specificalEPSS 0.8%CVE-2026-65927HIGHApache Tomcat: RewriteValve [N] restarts at the second rule and may bypass access controlEPSS 0.8%CVE-2023-4260MEDIUMPotential off-by-one buffer overflow vulnerability in the Zephyr FS subsystemEPSS 0.8%CVE-2021-3999HIGHA flaw was found in glibc. An off-by-one buffer overflow and underflow in getcwd() may lead to memory corruption when the size of the bufferEPSS 0.7%CVE-2026-7831HIGHUltraVNC viewer off-by-one stack overflow in ServerInit desktop name parsingEPSS 0.7%CVE-2026-42015MEDIUMGnutls: gnutls: memory corruption due to off-by-one error in pkcs#12 bag handlingEPSS 0.7%CVE-2023-4259HIGHPotential buffer overflow vulnerabilities in the Zephyr eS-WiFi driverEPSS 0.7%CVE-2023-46247HIGHVyper has incorrect storage layout for contracts containing large arraysEPSS 0.7%CVE-2026-48689CRITICALFastNetMon Community Edition through 1.2.9 contains an off-by-one heap-based buffer overflow in the dynamic_binary_buffer_t class (src/dynamEPSS 0.7%CVE-2023-41880LOWMiscompilation of wasm `i64x2.shr_s` instruction with constant input on x86_64EPSS 0.7%CVE-2025-53014LOWImageMagick has Heap Buffer Overflow in InterpretImageFilenameEPSS 0.6%CVE-2023-30546CRITICALContiki-NG has off-by-one error in Antelope DBMSEPSS 0.6%