Add additional check for read permissions

Signed-off-by: Julius Härtl <jus@bitgrid.net>
This commit is contained in:
Julius Härtl 2019-07-22 17:22:05 +02:00
parent 3674f6fa2d
commit e43b341b04
No known key found for this signature in database
GPG key ID: 4C614C6ED2CDE6DF

View file

@ -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;
}));
}