diff options
author | Morris Jobke <hey@morrisjobke.de> | 2015-08-24 09:14:27 +0200 |
---|---|---|
committer | Morris Jobke <hey@morrisjobke.de> | 2015-08-24 09:14:27 +0200 |
commit | 40b1054530229139a5cacf28ed4b883d52835ad6 (patch) | |
tree | ae6693babddc83bf4c77ef7890726a6b517ed392 /lib/base.php | |
parent | 510010e774c4019b7fc616c90085649abb7afac3 (diff) | |
parent | df2ce8a075d70a2180f2b1c7685b19db6d3ce91b (diff) | |
download | nextcloud-server-40b1054530229139a5cacf28ed4b883d52835ad6.tar.gz nextcloud-server-40b1054530229139a5cacf28ed4b883d52835ad6.zip |
Merge pull request #18254 from owncloud/mitigate-breach
Add mitigation against BREACH
Diffstat (limited to 'lib/base.php')
-rw-r--r-- | lib/base.php | 13 |
1 files changed, 1 insertions, 12 deletions
diff --git a/lib/base.php b/lib/base.php index 42e1d7f8586..1f921b13e67 100644 --- a/lib/base.php +++ b/lib/base.php @@ -134,18 +134,7 @@ class OC { OC_Config::$object = new \OC\Config(self::$configDir); OC::$SUBURI = str_replace("\\", "/", substr(realpath($_SERVER["SCRIPT_FILENAME"]), strlen(OC::$SERVERROOT))); - /** - * FIXME: The following line is required because of a cyclic dependency - * on IRequest. - */ - $params = [ - 'server' => [ - 'SCRIPT_NAME' => $_SERVER['SCRIPT_NAME'], - 'SCRIPT_FILENAME' => $_SERVER['SCRIPT_FILENAME'], - ], - ]; - $fakeRequest = new \OC\AppFramework\Http\Request($params, null, new \OC\AllConfig(new \OC\SystemConfig())); - $scriptName = $fakeRequest->getScriptName(); + $scriptName = $_SERVER['SCRIPT_NAME']; if (substr($scriptName, -1) == '/') { $scriptName .= 'index.php'; //make sure suburi follows the same rules as scriptName |