summaryrefslogtreecommitdiffstats
path: root/apps
diff options
context:
space:
mode:
authorRobin Appelman <robin@icewind.nl>2018-11-27 16:54:00 +0100
committerRobin Appelman <robin@icewind.nl>2018-11-29 16:31:34 +0100
commit2c1f6331a4d6a5d4663d57858f10faa851e33d82 (patch)
tree7c31041fbc31aceb81d01177ae1b307cbc887b97 /apps
parent9f64149a38f1cd5f3942dd19720e335911d04f46 (diff)
downloadnextcloud-server-2c1f6331a4d6a5d4663d57858f10faa851e33d82.tar.gz
nextcloud-server-2c1f6331a4d6a5d4663d57858f10faa851e33d82.zip
Add interface to allow storages from opting out of encryption
As opposed to hard-coding a list of excluded storages Signed-off-by: Robin Appelman <robin@icewind.nl>
Diffstat (limited to 'apps')
-rw-r--r--apps/files_external/lib/Lib/Storage/OwnCloud.php3
-rw-r--r--apps/files_sharing/lib/External/Storage.php3
-rw-r--r--apps/files_sharing/lib/SharedStorage.php3
3 files changed, 6 insertions, 3 deletions
diff --git a/apps/files_external/lib/Lib/Storage/OwnCloud.php b/apps/files_external/lib/Lib/Storage/OwnCloud.php
index 3ee2b70ef22..04cd5ecf9af 100644
--- a/apps/files_external/lib/Lib/Storage/OwnCloud.php
+++ b/apps/files_external/lib/Lib/Storage/OwnCloud.php
@@ -25,6 +25,7 @@
*/
namespace OCA\Files_External\Lib\Storage;
+use OCP\Files\Storage\IDisableEncryptionStorage;
use Sabre\DAV\Client;
/**
@@ -34,7 +35,7 @@ use Sabre\DAV\Client;
* http://%host/%context/remote.php/webdav/%root
*
*/
-class OwnCloud extends \OC\Files\Storage\DAV{
+class OwnCloud extends \OC\Files\Storage\DAV implements IDisableEncryptionStorage {
const OC_URL_SUFFIX = 'remote.php/webdav';
public function __construct($params) {
diff --git a/apps/files_sharing/lib/External/Storage.php b/apps/files_sharing/lib/External/Storage.php
index dadb1def702..7411d3c51b6 100644
--- a/apps/files_sharing/lib/External/Storage.php
+++ b/apps/files_sharing/lib/External/Storage.php
@@ -39,10 +39,11 @@ use OCP\AppFramework\Http;
use OCP\Constants;
use OCP\Federation\ICloudId;
use OCP\Files\NotFoundException;
+use OCP\Files\Storage\IDisableEncryptionStorage;
use OCP\Files\StorageInvalidException;
use OCP\Files\StorageNotAvailableException;
-class Storage extends DAV implements ISharedStorage {
+class Storage extends DAV implements ISharedStorage, IDisableEncryptionStorage {
/** @var ICloudId */
private $cloudId;
/** @var string */
diff --git a/apps/files_sharing/lib/SharedStorage.php b/apps/files_sharing/lib/SharedStorage.php
index f9c4a85fac6..67868b512c3 100644
--- a/apps/files_sharing/lib/SharedStorage.php
+++ b/apps/files_sharing/lib/SharedStorage.php
@@ -39,6 +39,7 @@ use OC\Files\Storage\FailedStorage;
use OCP\Constants;
use OCP\Files\Cache\ICacheEntry;
use OCP\Files\NotFoundException;
+use OCP\Files\Storage\IDisableEncryptionStorage;
use OCP\Files\Storage\IStorage;
use OCP\Lock\ILockingProvider;
use OC\User\NoUserException;
@@ -46,7 +47,7 @@ use OC\User\NoUserException;
/**
* Convert target path to source path and pass the function call to the correct storage provider
*/
-class SharedStorage extends \OC\Files\Storage\Wrapper\Jail implements ISharedStorage {
+class SharedStorage extends \OC\Files\Storage\Wrapper\Jail implements ISharedStorage, IDisableEncryptionStorage {
/** @var \OCP\Share\IShare */
private $superShare;