From: Alexander Ebert Date: Tue, 14 May 2013 19:27:31 +0000 (+0200) Subject: RequestHandler now longer mis-redirects if SID is present X-Git-Tag: 2.0.0_Beta_1~187 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=15e38b84a761ee739fac710ddb58ac003125c806;p=GitHub%2FWoltLab%2FWCF.git RequestHandler now longer mis-redirects if SID is present --- diff --git a/wcfsetup/install/files/lib/system/request/RequestHandler.class.php b/wcfsetup/install/files/lib/system/request/RequestHandler.class.php index 9780c340cf..68a11ceec7 100644 --- a/wcfsetup/install/files/lib/system/request/RequestHandler.class.php +++ b/wcfsetup/install/files/lib/system/request/RequestHandler.class.php @@ -84,7 +84,9 @@ class RequestHandler extends SingletonFactory { if ($landingPage !== null && RouteHandler::getInstance()->isDefaultController()) { // check if redirect URL matches current URL $redirectURL = $landingPage->getLink(); - if (StringUtil::replace(RouteHandler::getHost(), '', $redirectURL) == $_SERVER['REQUEST_URI']) { + $relativeRoute = StringUtil::replace(RouteHandler::getHost(), '', $redirectURL); + + if ($relativeRoute == $_SERVER['REQUEST_URI'] || $relativeRoute == preg_replace('~([?&]s=[a-f0-9]{40})~', '', $_SERVER['REQUEST_URI'])) { $routeData['controller'] = $landingPage->getController(); } else {