decode-uri-componentに入力処理の遅延で サービス拒否される脆弱性
Summary
decode-uri-componentの0.5.1より前のバージョンには、不正な形式のパーセントエンコーディングを含む入力を処理すると、CPU負荷が二次関数的に増え、Node.jsのイベントループが止まる脆弱性があります。リクエストボディで大きな入力を送られると影響が大きくなるとされ、CVSS v4.0のスコアは8.2です。0.5.1以降の修正版に更新してください。
AI summary
Written by an external AI model and may contain mistakes. Check the original description and references below before acting on it.
decode-uri-componentの0.5.1より前のバージョンには、不正な形式のパーセントエンコーディングを含む入力を処理すると、CPU負荷が二次関数的に増え、Node.jsのイベントループが止まる脆弱性があります。リクエストボディで大きな入力を送られると影響が大きくなるとされ、CVSS v4.0のスコアは8.2です。0.5.1以降の修正版に更新してください。
Affected packages
| Ecosystem | Package | Affected | Fixed |
|---|---|---|---|
| SamVerschueren | decode-uri-component | — | — |
Original description The description as published by the source.
decode-uri-component provides a more robust alternative to decodeURIComponent. Prior to 0.5.1, decodeUriComponent in index.js falls back to customDecodeURIComponent after native decoding throws, and the fallback collects every distinct percent-encoded run before performing a full-string regular-expression replacement for each entry. Malformed input containing many distinct runs can therefore make both the number of replacements and the scanned input length grow together, causing quadratic CPU consumption and blocking the Node.js event loop; request-body inputs can reach the demonstrated size, while ordinary URL header limits reduce the practical delay. This issue is fixed in version 0.5.1.
Source: CVE.org (CVE Program・cvelistV5) NVD