Skip to content
OpenAdvisories
Critical · 9.1 CVE-2026-135803 EUVD-2026-133736GHSA-3gqv-8wv6-5qw7

Filesystem Path Treats Any Prefix Before "://" as a Root, Letting Paths Escape Their Base Directory

Published Nov 24, 2026 · Updated Nov 25, 2026 · Assigned by Symfony

Description

Most methods of Symfony\Component\Filesystem\Path rely on Path::split(), which takes everything before the first :// as the root of a path. It doesn't check that this prefix is a URI scheme, so the .. segments in that prefix are never resolved. PHP sees a scheme only at the start of a string. So /base/../x://../secret.txt is a plain local path to /secret.txt for PHP, while Path::isBasePath('/base', '/base/../x://../secret.txt') returns true. canonicalize(), join(), makeAbsolute() and makeRelative() are affected the same way.

Some applications check a path built from user input with isBasePath() or canonicalize(), and then open it. They can be made to read or write files outside the expected directory.

On Symfony 6.4 and later, the AssetMapper component builds with Path::join() the path of the files that a remote package references from its CSS. A malicious or compromised package can therefore make importmap:require or importmap:install write a file of its choice outside assets/vendor. For example, the CSS url(../../../../../public/x://shell.php) writes public/x:/shell.php.

A prefix is now a scheme only when PHP would look for a stream wrapper with that name. That is two or more letters, digits, +, - or ., followed by :// at the start of the path. Other prefixes are regular path segments, and the .. segments after them are resolved. Real schemes such as phar://, file://, vfs:// or compress.zlib:// keep working.

Affected products

VendorProductAffectedFixed
Symfony symfony/filesystem 5.4.0 – < 5.4.56, 6.0.0 – < 6.4.50, 7.0.0 – < 7.4.23, 8.0.0 – < 8.1.11 5.4.56
Symfony symfony/symfony 5.4.0 – < 5.4.56, 6.0.0 – < 6.4.50, 7.0.0 – < 7.4.23, 8.0.0 – < 8.1.11 5.4.56

Fixed in Linux distributions

Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.

ReleasePackageFixed inAdvisory
Debian 14 symfony 7.4.23+dfsg-1 —
Debian 13 symfony 6.4.50+dfsg-0+deb13u1 DSA-6617-1
Debian 12 symfony No fix yet —
ReleasePackageFixed inAdvisory
Ubuntu 26.10 symfony No fix yet —
Ubuntu 26.04 LTS symfony No fix yet —
Ubuntu 16.04 LTS symfony No fix yet —
Show 4 more (older releases, extended support, other products)
ReleasePackageFixed inAdvisory
Ubuntu Pro 24.04 LTS symfony No fix yet —
Ubuntu Pro 22.04 LTS symfony No fix yet —
Ubuntu Pro 20.04 LTS symfony No fix yet —
Ubuntu Pro 18.04 LTS symfony No fix yet —

Advisories 1

References