Falhas do tipo CWE-1333

407 resultados

Expressão regular com complexidade exponencial (ReDoS)

A aplicação usa uma regex que, em certos padrões de entrada, causa backtracking excessivo e consome CPU de forma exponencial. O motor regex tenta múltiplas combinações de correspondência antes de falhar ou suceder, podendo travar a aplicação ou deixá-la lenta demais para responder.

Exemplo

Um validador de email com regex como `(a+)+b` recebe a string `aaaaaaaaaaaaaaaaaaaaX` (sem o caractere final esperado). O motor testa todas as combinações de agrupamento do `a` repetido, levando tempo exponencial em relação ao tamanho da entrada.

Como mitigar

Use bibliotecas de parsing ou validação especializadas em vez de regex complexas (ex: bibliotecas de email ou URL). Se regex for necessária, teste com inputs longos malformados, limpe a entrada antes, ou use engines regex com proteção contra backtracking (como a do Rust).

CVE-2022-23514HIGHInefficient Regular Expression Complexity in LoofahEPSS 1.7%CVE-2022-42969MEDIUMThe py library through 1.11.0 for Python allows remote attackers to conduct a ReDoS (Regular expression Denial of Service) attack via a SubvEPSS 1.7%CVE-2022-25881MEDIUMThis affects versions of the package http-cache-semantics before 4.1.1. The issue can be exploited via malicious request header values sent EPSS 1.6%CVE-2021-35065HIGHThe glob-parent package before 6.0.1 for Node.js allows ReDoS (regular expression denial of service) attacks against the enclosure regular eEPSS 1.6%CVE-2021-43307MEDIUMExponential ReDoS in semver-regexEPSS 1.6%CVE-2023-36543Apache Airflow: ReDoS via dags functionEPSS 1.6%CVE-2022-25901MEDIUMVersions of the package cookiejar before 2.1.4 are vulnerable to Regular Expression Denial of Service (ReDoS) via the Cookie.parse function,EPSS 1.5%CVE-2022-21222MEDIUMRegular Expression Denial of Service (ReDoS)EPSS 1.5%CVE-2021-43306MEDIUMExponential ReDoS in jquery-validationEPSS 1.5%CVE-2024-26142HIGHRails possible ReDoS vulnerability in Accept header parsing in Action DispatchEPSS 1.5%CVE-2021-3842HIGHInefficient Regular Expression Complexity in nltk/nltkEPSS 1.5%CVE-2021-3795HIGHInefficient Regular Expression Complexity in sindresorhus/semver-regexEPSS 1.5%CVE-2022-23517HIGHInefficient Regular Expression Complexity in rails-html-sanitizerEPSS 1.5%CVE-2024-4067MEDIUMRegular Expression Denial of Service in micromatchEPSS 1.4%CVE-2024-49761MEDIUMREXML ReDoS vulnerabilityEPSS 1.4%CVE-2021-3822MEDIUMInefficient Regular Expression Complexity in josdejong/jsoneditorEPSS 1.4%CVE-2021-43805HIGHReDos vulnerability on guest checkout email validationEPSS 1.4%CVE-2022-36064MEDIUMShescape Inefficient Regular Expression Complexity vulnerabilityEPSS 1.4%CVE-2020-36649LOWmholt PapaParse papaparse.js redosEPSS 1.4%CVE-2024-3651MEDIUMDenial of Service via Quadratic Complexity in kjd/idnaEPSS 1.4%