From ac88bcbd5f03419e149dac2a080f8f206876547e Mon Sep 17 00:00:00 2001 From: Johannes Leuker Date: Tue, 8 Dec 2020 15:12:04 +0100 Subject: Add 'allow Symlinks' as an option to config.php Signed-off-by: Johannes Leuker --- lib/private/Files/Storage/Local.php | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'lib/private/Files/Storage') diff --git a/lib/private/Files/Storage/Local.php b/lib/private/Files/Storage/Local.php index 5d0ce596b11..81d1d083eb8 100644 --- a/lib/private/Files/Storage/Local.php +++ b/lib/private/Files/Storage/Local.php @@ -58,8 +58,6 @@ class Local extends \OC\Files\Storage\Common { protected $dataDirLength; - protected $allowSymlinks = false; - protected $realDataDir; public function __construct($arguments) { @@ -441,7 +439,8 @@ class Local extends \OC\Files\Storage\Common { $fullPath = $this->datadir . $path; $currentPath = $path; - if ($this->allowSymlinks || $currentPath === '') { + $allowSymlinks = \OC::$server->getConfig()->getSystemValue('localstorage.allowsymlinks', false); + if ($allowSymlinks || $currentPath === '') { return $fullPath; } $pathToResolve = $fullPath; -- cgit v1.2.3