summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThomas Müller <thomas.mueller@tmit.eu>2013-06-28 13:59:33 -0700
committerThomas Müller <thomas.mueller@tmit.eu>2013-06-28 13:59:33 -0700
commitdfa6aa25c3bec3cba027b5bf89f75303fe7bce06 (patch)
tree5b8f5cf93b52d914b9e81f42fb4083df658ca781
parentc2ac0fb4dfe9c31b14ab56798f8c1edbae62c994 (diff)
parentf726de3cabfd67b6aa2ab42ad27eb2fd90e84e27 (diff)
downloadnextcloud-server-dfa6aa25c3bec3cba027b5bf89f75303fe7bce06.tar.gz
nextcloud-server-dfa6aa25c3bec3cba027b5bf89f75303fe7bce06.zip
Merge pull request #3886 from owncloud/disable-public-upload-if-encryption-enabled-master
for now we disable public upload in case encryption is enabled
-rw-r--r--apps/files_sharing/public.php6
1 files changed, 5 insertions, 1 deletions
diff --git a/apps/files_sharing/public.php b/apps/files_sharing/public.php
index fa8c25fc98d..ef86013b3e7 100644
--- a/apps/files_sharing/public.php
+++ b/apps/files_sharing/public.php
@@ -147,7 +147,11 @@ if (isset($path)) {
$tmpl->assign('mimetype', \OC\Files\Filesystem::getMimeType($path));
$tmpl->assign('fileTarget', basename($linkItem['file_target']));
$tmpl->assign('dirToken', $linkItem['token']);
- $tmpl->assign('allowPublicUploadEnabled', (($linkItem['permissions'] & OCP\PERMISSION_CREATE) ? true : false ));
+ $allowPublicUploadEnabled = (($linkItem['permissions'] & OCP\PERMISSION_CREATE) ? true : false );
+ if (\OCP\App::isEnabled('files_encryption')) {
+ $allowPublicUploadEnabled = false;
+ }
+ $tmpl->assign('allowPublicUploadEnabled', $allowPublicUploadEnabled);
$tmpl->assign('uploadMaxFilesize', $maxUploadFilesize);
$tmpl->assign('uploadMaxHumanFilesize', OCP\Util::humanFileSize($maxUploadFilesize));