Weaknesses of type CWE-674

458 results

Recursão descontrolada

Ocorre quando uma função chama a si mesma (ou a outras funções em cadeia) sem limite adequado de profundidade, consumindo toda a pilha de execução até causar travamento ou crash. O risco é permitir que dados não validados ou entrada do usuário definam a profundidade da recursão, tornando fácil um ataque de negação de serviço.

Example

Um parser XML que processa elementos aninhados chamando recursivamente a si mesmo para cada nível, sem verificar a profundidade máxima. Um atacante envia um arquivo com milhares de tags aninhadas e a aplicação entra em stack overflow.

How to mitigate

Implemente um limite máximo de profundidade de recursão (contador ou limite de pilha) e lance exceção se ultrapassado. Prefira iteração com pilha explícita quando possível, ou valide e sanitize a entrada para garantir que a complexidade da estrutura de dados não ultrapasse limites razoáveis.

CVE-2022-31628LOWphar wrapper can occur dos when using quine gzip fileEPSS 0.6%CVE-2025-30193HIGHDenial of service via crafted TCP exchangeEPSS 0.6%CVE-2026-73321HIGHXenForo < 2.3.13 Uncontrolled Recursion DoS via BBCode ParserEPSS 0.6%CVE-2026-77465HIGHtoml-node: Uncontrolled RecursionEPSS 0.6%CVE-2026-84851HIGHUncontrolled recursion in the Ion reader in Amazon Ion-C before 1.1.6EPSS 0.6%CVE-2026-6479HIGHPostgreSQL SSL/GSS init causes denial of service, via uncontrolled recursionEPSS 0.6%CVE-2026-112895HIGHPillow: Unbounded recursion parsing a PDF page tree or trailer chain (incomplete fix for CVE-2026-42310)EPSS 0.6%CVE-2026-52132HIGHllama.cpp through commit 97f06e9, when started with the --reranking flag, allows remote attackers to cause a denial of service (std::bad_allEPSS 0.6%CVE-2026-102281HIGHNest: Remote process termination via a deeply nested microservice message patternEPSS 0.6%CVE-2025-71382HIGHMuPDF < 1.27.0-rc1 Stack Exhaustion DoS via EPUB CSS RenderingEPSS 0.6%CVE-2024-57699HIGHA security issue was found in Netplex Json-smart 2.5.0 through 2.5.1. When loading a specially crafted JSON input, containing a large numberEPSS 0.6%CVE-2026-82604MEDIUMBareBones BBEdit Java Language recursionEPSS 0.6%CVE-2026-74795HIGHScriban before 6.6.0 Denial of Service via Uncontrolled RecursionEPSS 0.6%CVE-2026-72686MEDIUMUncontrolled Recursion in Elasticsearch Leading to Denial of ServiceEPSS 0.6%CVE-2026-72683MEDIUMUncontrolled Recursion in Elasticsearch Leading to Denial of ServiceEPSS 0.6%CVE-2026-90472MEDIUMmsgpack-java through 0.9.12 Stack Overflow via Nested ArraysEPSS 0.6%CVE-2026-32933HIGHAutoMapper Vulnerable to Denial of Service (DoS) via Uncontrolled RecursionEPSS 0.6%CVE-2023-29001HIGHUncontrolled recursion due to insufficient validation of the IPv6 source routing header in Contiki-NGEPSS 0.6%CVE-2026-120135HIGHApache Thrift: Java TProtocolUtil.skip() does not limit the recursion depth by defaultEPSS 0.6%CVE-2026-82230HIGHApache bRPC: Stack Exhaustion via Unbounded Recursion in mcpack2pb ParserEPSS 0.5%