diff options
author | Michael Gapczynski <mtgap@owncloud.com> | 2012-08-31 17:31:28 -0400 |
---|---|---|
committer | Michael Gapczynski <mtgap@owncloud.com> | 2012-08-31 17:31:28 -0400 |
commit | efa0478d2d6c78639d5839c9014f25dac1f11d98 (patch) | |
tree | 9a886141df70a54f5f37e07e5edc8aeb7064882f /lib/files.php | |
parent | c07eb4fec69ad8d691a1168f5a09db5e52f65589 (diff) | |
download | nextcloud-server-efa0478d2d6c78639d5839c9014f25dac1f11d98.tar.gz nextcloud-server-efa0478d2d6c78639d5839c9014f25dac1f11d98.zip |
Remove share permission for encrypted files
Diffstat (limited to 'lib/files.php')
-rw-r--r-- | lib/files.php | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/files.php b/lib/files.php index a303c078728..b8af5e04b71 100644 --- a/lib/files.php +++ b/lib/files.php @@ -56,7 +56,11 @@ class OC_Files { foreach ($files as &$file) { $file['directory'] = $directory; $file['type'] = ($file['mimetype'] == 'httpd/unix-directory') ? 'dir' : 'file'; - $permissions = OCP\Share::PERMISSION_READ | OCP\Share::PERMISSION_SHARE; + $permissions = OCP\Share::PERMISSION_READ; + // NOTE: Remove check when new encryption is merged + if (!$file['encrypted']) { + $permissions |= OCP\Share::PERMISSION_SHARE; + } if ($file['type'] == 'dir' && $file['writable']) { $permissions |= OCP\Share::PERMISSION_CREATE; } |