Falhas do tipo CWE-704

104 resultados

Conversão ou casting incorreto de tipo

Ocorre quando o código converte um objeto ou dado de um tipo para outro de forma inadequada, sem validar se a conversão é segura ou se preserva a semântica esperada. Isso pode levar a interpretações erradas dos dados, corrupção de estado ou execução de código com privilégios indevidos.

Exemplo

Um aplicativo recebe um ponteiro genérico (void*) de rede e faz casting direto para uma estrutura específica sem verificar o tipo real. Se o servidor enviar dados de um tipo diferente, o acesso aos campos interpretará lixo de memória como valores válidos, causando lógica corrompida ou crash.

Como mitigar

Implemente validação de tipo antes de qualquer conversão (use type tags, discriminadores ou metadados). Prefira conversões explícitas que falham seguramente em vez de casts silenciosos; em linguagens como C, use structs com type identifiers ou serialize/desserialize com schema validation (JSON Schema, Protocol Buffers).

CVE-2024-5436HIGHType Confusion in Snapchat LenscoreEPSS 0.5%CVE-2020-11725HIGHsnd_ctl_elem_add in sound/core/control.c in the Linux kernel through 5.6.3 has a count=info->owner line, which later affects a private_size*EPSS 0.5%CVE-2026-73429MEDIUMRussh: client wrong-length X25519 `clone_from_slice` panic (pre-auth DoS)EPSS 0.5%CVE-2022-41890MEDIUM`CHECK` fail in `BCast` overflow in TensorflowEPSS 0.5%CVE-2025-40540CRITICALSolarWinds Serv-U Type Confusion Remote Code Execution VulnerabilityEPSS 0.5%CVE-2026-27809MEDIUMpsd-tools: Compression module has unguarded zlib decompression, missing dimension validation, and hardening gapsEPSS 0.5%CVE-2025-40539CRITICALSolarWinds Serv-U Type Confusion Remote Code Execution VulnerabilityEPSS 0.5%CVE-2026-45685HIGHOpenTelemetry eBPF Instrumentation: MongoDB parser panics on malformed wire messagesEPSS 0.5%CVE-2026-50278MEDIUMiccDEV: CIccEmbedIO::Read8() size_t underflowEPSS 0.5%CVE-2026-48140HIGHUnchecked enum cast vulnerability in NI grpc-device in BeginSidebandStreamEPSS 0.4%CVE-2022-41911MEDIUMInvalid char to bool conversion when printing a tensor in TensorflowEPSS 0.4%CVE-2023-6249HIGHipm: signed to unsigned conversion problem in esp32_ipm_sendEPSS 0.4%CVE-2026-53798MEDIUMrsync < 3.5.0 Privilege Confusion via name-converter uid/gid mappingEPSS 0.4%CVE-2026-10080MEDIUMBoards plugin panics on WebSocket command with non-string field typesEPSS 0.4%CVE-2026-44324MEDIUMfree5GC: UDR nudr-dr DELETE amf-subscriptions panics on missing UE state via nil interface type assertion (single authenticated request)EPSS 0.4%CVE-2026-121589MEDIUMspatie url-signer URL Validation AbstractUrlSigner.php validate type conversionEPSS 0.4%CVE-2026-20249HIGHCisco Secure Firewall Adaptive Security Appliance and Secure Firewall Threat Defense Software IKEv2 Certificate Authentication Denial of Service VulnerabilityEPSS 0.4%CVE-2025-1057MEDIUMKeylime: keylime registrar dos due to incompatible database entry handlingEPSS 0.4%CVE-2026-58822CRITICALIn multiple functions of ftsmooth.c, there is a possible memory safety issue due to improper casting. This could lead to remote code executiEPSS 0.4%CVE-2021-4456MEDIUMNet::CIDR versions before 0.24 for Perl mishandle leading zeros in IP CIDR addresses, which may have unspecified impactEPSS 0.4%