diff options
author | Robin Appelman <icewind@owncloud.com> | 2014-06-05 12:45:33 +0200 |
---|---|---|
committer | Robin Appelman <icewind@owncloud.com> | 2014-06-06 09:56:02 +0200 |
commit | 60ea4388edb3f3c5aebb3afbedc0ff5c29bc4c7b (patch) | |
tree | 2ea1a269ba37398b9076c9f021fd2650e2d8d2a5 /apps/files_sharing | |
parent | 3459f99dd6b737d73881504fd7103679fc1d7fe6 (diff) | |
download | nextcloud-server-60ea4388edb3f3c5aebb3afbedc0ff5c29bc4c7b.tar.gz nextcloud-server-60ea4388edb3f3c5aebb3afbedc0ff5c29bc4c7b.zip |
Limit permissions to share permissions
Diffstat (limited to 'apps/files_sharing')
-rw-r--r-- | apps/files_sharing/lib/cache.php | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/apps/files_sharing/lib/cache.php b/apps/files_sharing/lib/cache.php index f6c42e930d1..d0919f0dfdc 100644 --- a/apps/files_sharing/lib/cache.php +++ b/apps/files_sharing/lib/cache.php @@ -94,6 +94,7 @@ class Shared_Cache extends Cache { $data['is_share_mount_point'] = true; } $data['uid_owner'] = $this->storage->getOwner($file); + $data['permissions'] = $data['permissions'] & $this->storage->getPermissions(''); return $data; } } else { @@ -130,6 +131,7 @@ class Shared_Cache extends Cache { $data['name'] = basename($this->storage->getMountPoint()); $data['is_share_mount_point'] = true; } + $data['permissions'] = $data['permissions'] & $this->storage->getPermissions(''); return $data; } return false; @@ -157,6 +159,7 @@ class Shared_Cache extends Cache { $sourceFolderContent[$key]['path'] = $dir . $c['name']; $sourceFolderContent[$key]['uid_owner'] = $parent['uid_owner']; $sourceFolderContent[$key]['displayname_owner'] = $parent['uid_owner']; + $sourceFolderContent[$key]['permissions'] = $sourceFolderContent[$key]['permissions'] & $this->storage->getPermissions(''); } return $sourceFolderContent; |