Open
Description
I'm using React Router as a...
library
Reproduction
When a URL contains a newline character (either as %0a
), the system throws an error but fails to properly handle it in the routing layer.
example:
https://reactrouter.com/home/%0a

System Info
System:
OS: macOS 15.4.1
CPU: (10) arm64 Apple M2 Pro
Memory: 104.27 MB / 16.00 GB
Shell: 5.9 - /bin/zsh
Binaries:
Node: 23.10.0 - /opt/homebrew/opt/node/bin/node
npm: 10.9.2 - /opt/homebrew/opt/node/bin/npm
pnpm: 10.5.2 - /opt/homebrew/bin/pnpm
Browsers:
Chrome: 135.0.7049.115
Safari: 18.4
npmPackages:
react-router: ^7.5.3 => 7.5.3
Used Package Manager
npm
Expected Behavior
Caught by wildcard route (for 404 pages)
Actual Behavior
throws a server error