diff options
author | Julius Härtl <jus@bitgrid.net> | 2021-01-29 11:26:19 +0100 |
---|---|---|
committer | backportbot[bot] <backportbot[bot]@users.noreply.github.com> | 2021-02-01 11:13:44 +0000 |
commit | fcfa39183c2419608950bc00c359aea8365cf24b (patch) | |
tree | 3f51419e3747a7a9014afe625d099dadbbe454b4 /apps/dav | |
parent | 20cc5584f9f1eb3296c64a55c21c3f1525f2bcd2 (diff) | |
download | nextcloud-server-fcfa39183c2419608950bc00c359aea8365cf24b.tar.gz nextcloud-server-fcfa39183c2419608950bc00c359aea8365cf24b.zip |
Properly handle SMB ACL blocking scanning a directory
This makes sure that a possible ForbiddenException is properly passed
through the storage as a ForbiddenException and can be catched when
trying to fetch the quota info of a parent folder
Signed-off-by: Julius Härtl <jus@bitgrid.net>
Diffstat (limited to 'apps/dav')
-rw-r--r-- | apps/dav/lib/Connector/Sabre/Directory.php | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/apps/dav/lib/Connector/Sabre/Directory.php b/apps/dav/lib/Connector/Sabre/Directory.php index 8718933bcde..e23c7a236ab 100644 --- a/apps/dav/lib/Connector/Sabre/Directory.php +++ b/apps/dav/lib/Connector/Sabre/Directory.php @@ -41,6 +41,7 @@ use OCA\DAV\Connector\Sabre\Exception\InvalidPath; use OCP\Files\FileInfo; use OCP\Files\ForbiddenException; use OCP\Files\InvalidPathException; +use OCP\Files\NotPermittedException; use OCP\Files\StorageNotAvailableException; use OCP\Lock\ILockingProvider; use OCP\Lock\LockedException; @@ -343,6 +344,8 @@ class Directory extends \OCA\DAV\Connector\Sabre\Node implements \Sabre\DAV\ICol return [0, 0]; } catch (\OCP\Files\StorageNotAvailableException $e) { return [0, 0]; + } catch (NotPermittedException $e) { + return [0, 0]; } } |