From 47e35c40347987b2b43b8a47ae46b6934bc15f9f Mon Sep 17 00:00:00 2001 From: Ralf Becker Date: Fri, 10 Sep 2021 14:08:42 +0200 Subject: [PATCH] * Filemanager/WebDAV: fix mounting WebDAV URL as webdavs://user:pass@host/path --- composer.json | 2 +- composer.lock | 15 +++++++-------- filemanager/cli.php | 5 ----- filemanager/inc/class.filemanager_admin.inc.php | 2 +- 4 files changed, 9 insertions(+), 15 deletions(-) diff --git a/composer.json b/composer.json index 824b56571f..94b6b20ce1 100644 --- a/composer.json +++ b/composer.json @@ -94,7 +94,7 @@ "egroupware/status": "self.version", "egroupware/swoolepush": "self.version", "egroupware/tracker": "self.version", - "egroupware/webdav": "dev-master", + "egroupware/webdav": "^v0.3.1", "egroupware/z-push-dev": "^2.5", "giggsey/libphonenumber-for-php": "^8.12", "npm-asset/as-jqplot": "1.0.*", diff --git a/composer.lock b/composer.lock index 69c522852d..d702ebddb2 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "11c4709df1fbb8c2d7b55b3f2916a428", + "content-hash": "210ce7c8e74551a16bebace0ffa679b8", "packages": [ { "name": "adldap2/adldap2", @@ -1583,16 +1583,16 @@ }, { "name": "egroupware/webdav", - "version": "dev-master", + "version": "v0.3.1", "source": { "type": "git", "url": "https://github.com/EGroupware/WebDAV.git", - "reference": "889da78b6489965df8a379ccdc25853fe74da199" + "reference": "554b8ed3fb3bc98427f0c1edbba7f9bab9894d4c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/EGroupware/WebDAV/zipball/889da78b6489965df8a379ccdc25853fe74da199", - "reference": "889da78b6489965df8a379ccdc25853fe74da199", + "url": "https://api.github.com/repos/EGroupware/WebDAV/zipball/554b8ed3fb3bc98427f0c1edbba7f9bab9894d4c", + "reference": "554b8ed3fb3bc98427f0c1edbba7f9bab9894d4c", "shasum": "" }, "require": { @@ -1631,7 +1631,7 @@ "stream", "wrapper" ], - "time": "2020-09-23T16:16:07+00:00" + "time": "2021-09-10T11:59:20+00:00" }, { "name": "egroupware/z-push-dev", @@ -10718,8 +10718,7 @@ "egroupware/smallpart": 20, "egroupware/status": 20, "egroupware/swoolepush": 20, - "egroupware/tracker": 20, - "egroupware/webdav": 20 + "egroupware/tracker": 20 }, "prefer-stable": true, "prefer-lowest": false, diff --git a/filemanager/cli.php b/filemanager/cli.php index 3819b78de4..e0db48ca3b 100755 --- a/filemanager/cli.php +++ b/filemanager/cli.php @@ -484,11 +484,6 @@ function load_wrapper($url) { switch($scheme) { - case 'webdav': - case 'webdavs': - require_once('HTTP/WebDAV/Client.php'); - break; - default: if (!isset($GLOBALS['egw']) && !in_array($scheme,array('smb','imap')) && ($user = parse_url($url,PHP_URL_USER)) && ($pass = parse_url($url,PHP_URL_PASS))) diff --git a/filemanager/inc/class.filemanager_admin.inc.php b/filemanager/inc/class.filemanager_admin.inc.php index 690845225d..047a7671e9 100644 --- a/filemanager/inc/class.filemanager_admin.inc.php +++ b/filemanager/inc/class.filemanager_admin.inc.php @@ -261,7 +261,7 @@ class filemanager_admin extends filemanager_ui { $content['mounts'][$n++] = array( 'path' => $path, - 'url' => $url, + 'url' => preg_replace('#://([^:@/]+):([^@/]+)@#', '://$1:****@', $url), ); $readonlys["disable[$path]"] = !$this->versioning || !Vfs::$is_root || Vfs::parse_url($url,PHP_URL_SCHEME) != $this->versioning;