CVE-2017-16790 Symfony SSRF Vulnerability via Form Component

Medium 6.5 Published Updated

Attackers can read arbitrary server files by submitting crafted POST data to Symfony form FileType fields, exposing sensitive information.

Exploited in the wild
Not known
Login needed
Any signed-in user
Attackable
Over the internet
Victim action needed
Not needed
Fix
Available

What is CVE-2017-16790?

CVE-2017-16790 is a medium-severity path traversal vulnerability in Debian Debian Linux, published on 6 Aug 2018. Any signed-in user can exploit it over the network, with no action from the victim.

Official description

An issue was discovered in Symfony before 2.7.38, 2.8.31, 3.2.14, 3.3.13, 3.4-BETA5, and 4.0-BETA5. When a form is submitted by the user, the request handler classes of the Form component merge POST data and uploaded files data into one array. This big array forms the data that are then bound to the form. At this stage there is no difference anymore between submitted POST data and uploaded files. A user can send a crafted HTTP request where the value of a "FileType" is sent as normal POST data that could be interpreted as a local file path on the server-side (for example, "file:///etc/passwd"). If the application did not perform any additional checks about the value submitted to the "FileType", the contents of the given file on the server could have been exposed to the attacker.

Weakness: CWE-20

Which versions are affected by CVE-2017-16790?

16 open source packages ship an affected version, including symfony/form and symfony/symfony. It affects 2 products.

PackageAffectedFixed in
symfony/form PackagistFrom 2.7.02.7.38
symfony/form PackagistFrom 2.7.02.7.38
symfony/form PackagistFrom 2.8.02.8.31
symfony/form PackagistFrom 2.8.02.8.31
symfony/form PackagistFrom 3.0.03.2.14
symfony/form PackagistFrom 3.0.03.2.14
10 more packages
symfony/form PackagistFrom 3.3.03.3.13
symfony/form PackagistFrom 3.3.03.3.13
symfony/symfony PackagistFrom 2.7.02.7.38
symfony/symfony PackagistFrom 2.7.02.7.38
symfony/symfony PackagistFrom 2.8.02.8.31
symfony/symfony PackagistFrom 2.8.02.8.31
symfony/symfony PackagistFrom 3.0.03.2.14
symfony/symfony PackagistFrom 3.0.03.2.14
symfony/symfony PackagistFrom 3.3.03.3.13
symfony/symfony PackagistFrom 3.3.03.3.13

Products include Debian Debian Linux, Sensiolabs Symfony.

How do I fix CVE-2017-16790?

Upgrade symfony/form to a fixed version for your release line: 2.7.38, 2.8.31, 3.2.14 or 3.3.13.

Upgrade, and resolve every user-supplied path against an allowed base folder before opening it. More about Path traversal.

Is CVE-2017-16790 being exploited?

There is no known exploitation of CVE-2017-16790 in the wild and no public exploit code.

All Debian Debian Linux vulnerabilities

Sources

Also known as DEBIAN-CVE-2017-16790, GHSA-cqqh-94r6-wjrg, UBUNTU-CVE-2017-16790.

Is CVE-2017-16790 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free