Fallos del tipo CWE-195

37 resultados

Erro de conversão de sinal para sem sinal

Ocorre quando um valor inteiro com sinal (negativo ou positivo) é convertido para inteiro sem sinal sem validação prévia. Se o valor original é negativo, a conversão resulta em um número muito grande (devido à representação em complemento de dois), causando comportamentos inesperados como leituras fora dos limites de buffers, loops infinitos ou desvios de validações de segurança.

Ejemplo

Um desenvolvedor lê um tamanho de dados de um arquivo (int com sinal) e passa direto para malloc() ou memcpy() que esperam um unsigned int. Se o arquivo contiver -1, a conversão automática transforma isso em 4294967295 bytes em uma máquina 32-bit, alocando memória gigantesca ou copiando dados além do esperado.

Cómo mitigar

Valide sempre valores com sinal antes de converter para sem sinal: verifique se o valor é >= 0 e menor que o limite esperado. Use tipos explícitos em casts e ferramentas de análise estática para detectar conversões suspeitas. Em C, prefira operações que não façam conversão implícita entre os tipos.

CVE-2026-74220HIGHU-Boot before 2026.10-rc5 Buffer Overflow via NFS READ ReplyEPSS 0.3%CVE-2024-25388HIGHdrivers/wlan/wlan_mgmt,c in RT-Thread through 5.0.2 has an integer signedness error and resultant buffer overflow.EPSS 0.3%CVE-2026-115679MEDIUMArm Keil MDK-Middleware 8.3.0 may allow out-of-bounds reads and writes to the FTP Server RX BufferEPSS 0.3%CVE-2026-102639HIGHMobilityDB through 1.3.0 Out-of-bounds Read DoS via WKB DeserializationEPSS 0.3%CVE-2026-49840CRITICALFreeSWITCH: Pre-authentication heap buffer overflow in libesl `Content-Length` parsingEPSS 0.3%CVE-2026-55737MEDIUMHeap pointer corruption via signed/unsigned mismatch in LARGE_TUPLE_EXT decoding in erts external term format decoderEPSS 0.3%CVE-2025-65495HIGHInteger signedness error in tls_verify_call_back() in src/coap_openssl.c in OISM libcoap 4.3.5 allows remote attackers to cause a denial of EPSS 0.3%CVE-2025-30646HIGHJunos OS and Junos OS Evolved: Receipt of a malformed LLDP TLV results in l2cpd crashEPSS 0.3%CVE-2026-101937HIGHJunos OS: SRX Series: An attacker causes data-plane denial of service when chassis-cluster high availability is usedEPSS 0.2%CVE-2026-70388HIGHMemory Corruption via Integer Underflow in Message Length ValidationEPSS 0.2%CVE-2026-18444MEDIUMInteger Conversion Vulnerability Resulting in an Out of Bounds Read in NI LabVIEWEPSS 0.2%CVE-2026-82943MEDIUMOut-of-Bounds Read via Unchecked Length ValuesEPSS 0.2%CVE-2023-28063MEDIUM Dell BIOS contains a Signed to Unsigned Conversion Error vulnerability. A local authenticated malicious user with admin privileges could poEPSS 0.2%CVE-2026-110735LOWGodot Engine through 4.7.2 has a heap out-of-bounds write in the binary resource loader (core/io/resource_format_binary.cpp, ResourceLoaderBEPSS 0.2%CVE-2026-115921MEDIUMONNX: Null Pointer Dereference in ScanInferenceFunction Due to Missing Required AttributeEPSS 0.1%CVE-2025-24792MEDIUMSnowflake PHP PDO Driver has a Signed-to-Unsigned Conversion ErrorEPSS 0.1%CVE-2023-33034HIGHSigned-to-unsigned conversion error in AudioEPSS 0.1%