diff options
author | Robin Appelman <icewind@owncloud.com> | 2015-01-21 15:04:18 +0100 |
---|---|---|
committer | Robin Appelman <icewind@owncloud.com> | 2015-01-21 15:04:18 +0100 |
commit | 04075eba6b83a71a9af17bc2cfcbdcfe31a76af2 (patch) | |
tree | 892e7e5460bea7a0c90440e29631b47defaa7424 /lib | |
parent | ff5715779c56ceacc870307bf25f4e769ff22a1a (diff) | |
download | nextcloud-server-04075eba6b83a71a9af17bc2cfcbdcfe31a76af2.tar.gz nextcloud-server-04075eba6b83a71a9af17bc2cfcbdcfe31a76af2.zip |
Remove duplicated slashes from the requested url
Diffstat (limited to 'lib')
-rw-r--r-- | lib/private/request.php | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/private/request.php b/lib/private/request.php index 3c33dfc340a..3bf7d94d9cf 100644 --- a/lib/private/request.php +++ b/lib/private/request.php @@ -278,6 +278,8 @@ class OC_Request { $requestUri = '/' . ltrim($requestUri, '/'); } + $requestUri = preg_replace('%/{2,}%', '/', $requestUri); + // Remove the query string from REQUEST_URI if ($pos = strpos($requestUri, '?')) { $requestUri = substr($requestUri, 0, $pos); |