diff --git a/apps/dav/lib/Connector/Sabre/Directory.php b/apps/dav/lib/Connector/Sabre/Directory.php index 579dbbabf4435da74b7543e58a1e33ab27dd2c0d..435f47ee5616887aca6ae5ca996132627a580216 100644 --- a/apps/dav/lib/Connector/Sabre/Directory.php +++ b/apps/dav/lib/Connector/Sabre/Directory.php @@ -247,6 +247,8 @@ class Directory extends \OCA\DAV\Connector\Sabre\Node } try { if (!$this->info->isReadable()) { + // return 403 instead of 404 because a 404 would make + // the caller believe that the collection itself does not exist throw new Forbidden('No read permissions'); } $folderContent = $this->fileView->getDirectoryContent($this->path);