UrlGenerator Lets Host Placeholder Values Send Generated URLs to Another Host
- CVE-2026-133754
- EUVD-2026-135243
Description
UrlGenerator puts the values of host placeholders into the generated URL without encoding them. Their default requirement, [^.]++, accepts /, @, #, ?, \, % and :. With the host {tenant}.example.com, the value evil%2Ecom# gives https://evil%2Ecom#.example.com/dashboard, which browsers send to evil.com. This works even when requirements are checked. Unicode full stops like 。 have the same effect, since IDNA maps them to .. Applications are exposed when untrusted values reach host placeholders, for example when they pass the query string of the request to url(). A route that uses RedirectController::redirectAction() with keepQueryParams: true does the same, when the target route has a host placeholder that the redirecting route doesn't define. UrlGenerator now rejects host placeholder values that contain a character that is forbidden in a host. These characters are C0 controls, space, #, %, /, :, <, >, ?, @, [, \, ], ^, | and DEL. Unicode full stops are rejected too. This check applies whatever strict_requirements is set to. When strict_requirements is false or null, the generator logs an error and returns an empty string instead of throwing. Host placeholder values can still be an IPv6 literal like [::1], but they can't contain a port anymore.
Text from the CVE.org record.
Recommendation
Symfony symfony/routing
- If you run a version from 8.0.0 to before 8.1.12update to 8.1.12 or laterMinor version change: check the release notes
- If you run a version from 7.0.0 to before 7.4.24update to 7.4.24 or laterMinor version change: check the release notes
- If you run a version from 6.0.0 to before 6.4.51update to 6.4.51 or laterMinor version change: check the release notes
- If you run a version before 5.4.57update to 5.4.57 or later
Symfony symfony/symfony
- If you run a version from 8.0.0 to before 8.1.12update to 8.1.12 or laterMinor version change: check the release notes
- If you run a version from 7.0.0 to before 7.4.24update to 7.4.24 or laterMinor version change: check the release notes
- If you run a version from 6.0.0 to before 6.4.51update to 6.4.51 or laterMinor version change: check the release notes
- If you run a version before 5.4.57update to 5.4.57 or later
Taken from the version ranges of the CVE.org record. Check the vendor advisory: nothing is said about versions the ranges do not list. Breaking-change risk is read from the version numbers only.
Affected
Symfony symfony/routing
Affected versions Fixed in from 8.0.0 to before 8.1.12 8.1.12 from 7.0.0 to before 7.4.24 7.4.24 from 6.0.0 to before 6.4.51 6.4.51 before 5.4.57 5.4.57 Symfony symfony/symfony
Affected versions Fixed in from 8.0.0 to before 8.1.12 8.1.12 from 7.0.0 to before 7.4.24 7.4.24 from 6.0.0 to before 6.4.51 6.4.51 before 5.4.57 5.4.57
Product versions from the CVE.org record.
Timeline
- Published
Related news
No article from the followed outlets names this vulnerability.