There is a known bug which causes REQUEST_URI to be ISO-encoded, even though there is a hotfix enabled, certain Plesk versions do not ship that fix. Since it is safe to rely on UNENCODED_URL, we'll fall back to this one.
$canoncialURL = parse_url(preg_replace('~[?&]s=[a-f0-9]{40}~', '', $this->canonicalURL));
// use $_SERVER['REQUEST_URI'] because it represents the URL used to access the site and not the internally rewritten one
- $requestURI = preg_replace('~[?&]s=[a-f0-9]{40}~', '', $_SERVER['REQUEST_URI']);
+ // IIS Rewrite-Module has a bug causing the REQUEST_URI to be ISO-encoded
+ $requestURI = (!empty($_SERVER['UNENCODED_URL'])) ? $_SERVER['UNENCODED_URL'] : $_SERVER['REQUEST_URI'];
+ $requestURI = preg_replace('~[?&]s=[a-f0-9]{40}~', '', $requestURI);
+
if (!StringUtil::isUTF8($requestURI)) {
$requestURI = StringUtil::convertEncoding('ISO-8859-1', 'UTF-8', $requestURI);
}