Skip to content

Symfony Allows URI Restrictions Bypass Via Double-Encoded String

Moderate severity GitHub Reviewed Published May 17, 2022 to the GitHub Advisory Database • Updated Feb 6, 2024

Package

composer symfony/http-foundation (Composer)

Affected versions

>= 2.0.0, < 2.0.19

Patched versions

2.0.19
composer symfony/routing (Composer)
>= 2.0.0, < 2.0.19
2.0.19
composer symfony/security (Composer)
>= 2.0.0, < 2.0.19
2.0.19
composer symfony/symfony (Composer)
>= 2.0.0, < 2.0.19
2.0.19

Description

On the Symfony 2.0.x version, there's a security issue that allows access to routes protected by a firewall even when the user is not logged in.

Both the Routing component and the Security component uses the path returned by getPathInfo() to match a Request. The getPathInfo() returns a decoded path, but the Routing component (Symfony\Component\Routing\Matcher\UrlMatcher) decodes the path a second time; whereas the Security component, Symfony\Component\HttpFoundation\RequestMatcher, does not.

This difference causes Symfony 2.0 to be vulnerable to double encoding attacks.

References

Published by the National Vulnerability Database Dec 27, 2012
Published to the GitHub Advisory Database May 17, 2022
Reviewed Aug 15, 2023
Last updated Feb 6, 2024

Severity

Moderate

Weaknesses

CVE ID

CVE-2012-6431

GHSA ID

GHSA-83c3-qx27-2rwr

Source code

No known source code
Checking history
See something to contribute? Suggest improvements for this vulnerability.