CVE-2026-29045: Unsafe Path Decode

Decoding a request path or URL using `decodeURIComponent` can introduce a path confusion vulnerability. `decodeURIComponent` decodes percent-encoded slashes (`%2F`) into literal slashes (`/`), whereas most application routers use `decodeURI`, which leaves them encoded. This discrepancy can allow an attacker to bypass route-based middleware protections (e.g.,

Provally CuratedPublic repositoryHighMedium confidenceVerifiedApache-2.0JS
greprules fetch cve-2026-29045-unsafe-path-decode --engine opengrep

Description

Decoding a request path or URL using `decodeURIComponent` can introduce a path confusion vulnerability. `decodeURIComponent` decodes percent-encoded slashes (`%2F`) into literal slashes (`/`), whereas most application routers use `decodeURI`, which leaves them encoded. This discrepancy can allow an attacker to bypass route-based middleware protections (e.g.,