Permalink
Browse files

merged branch Tobion/fix-double-encoding (PR #6363)

This PR was merged into the 2.0 branch.

Commits
-------

8b2c17f fix double-decoding in the routing system

Discussion
----------

fix double-decoding in the routing system

@fabpot @vicb This should fix it. You know what ;) Don't want to leak more information.
And the good thing, it's no hack nor does it break BC.
  • Loading branch information...
2 parents 75afdfe + 6e2698d commit 6319bda841b7b488c33c647e3b4e53b2bcd1f4db @fabpot fabpot committed Dec 20, 2012
Showing with 2 additions and 2 deletions.
  1. +2 −2 Http/HttpUtils.php
View
@@ -107,7 +107,7 @@ public function checkRequestPath(Request $request, $path)
{
if ('/' !== $path[0]) {
try {
- $parameters = $this->router->match($request->getPathInfo());
+ $parameters = $this->router->match(urlencode($request->getPathInfo()));
return $path === $parameters['_route'];
} catch (MethodNotAllowedException $e) {
@@ -129,7 +129,7 @@ private function resetLocale(Request $request)
}
try {
- $parameters = $this->router->match($request->getPathInfo());
+ $parameters = $this->router->match(urlencode($request->getPathInfo()));
if (isset($parameters['_locale'])) {
$context->setParameter('_locale', $parameters['_locale']);

0 comments on commit 6319bda

Please sign in to comment.