From e43b341b04c5e13424f2d833803c0e444f8ab3b2 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Julius=20H=C3=A4rtl?= Date: Mon, 22 Jul 2019 17:22:05 +0200 Subject: [PATCH] Add additional check for read permissions MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Julius Härtl --- lib/private/Files/Node/Folder.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/private/Files/Node/Folder.php b/lib/private/Files/Node/Folder.php index 7f908a757a0..19f04048779 100644 --- a/lib/private/Files/Node/Folder.php +++ b/lib/private/Files/Node/Folder.php @@ -447,7 +447,8 @@ class Folder extends Node implements \OCP\Files\Folder { return false; } $relative = $this->getRelativePath($node->getPath()); - return $relative !== null && $relative !== '/'; + return $relative !== null && $relative !== '/' + && ($cacheEntry->getPermissions() & \OCP\Constants::PERMISSION_READ) === \OCP\Constants::PERMISSION_READ; })); } -- 2.39.5