diff options
author | Joas Schilling <coding@schilljs.com> | 2019-06-27 14:54:28 +0200 |
---|---|---|
committer | Joas Schilling <coding@schilljs.com> | 2019-06-27 14:54:28 +0200 |
commit | 8c73c1ea5e2786d3d47e0553d98d0b727c26c6d6 (patch) | |
tree | a36741903b85a535eb7d07b270027ee035f391ca /apps/provisioning_api | |
parent | c63f1d8d39f0ccae4483c6c37a1ecf7fa9040b81 (diff) | |
download | nextcloud-server-8c73c1ea5e2786d3d47e0553d98d0b727c26c6d6.tar.gz nextcloud-server-8c73c1ea5e2786d3d47e0553d98d0b727c26c6d6.zip |
Don't allow to disable encryption via the API
Signed-off-by: Joas Schilling <coding@schilljs.com>
Diffstat (limited to 'apps/provisioning_api')
-rw-r--r-- | apps/provisioning_api/lib/Controller/AppConfigController.php | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/apps/provisioning_api/lib/Controller/AppConfigController.php b/apps/provisioning_api/lib/Controller/AppConfigController.php index 38483d2796c..6e61e10a2f2 100644 --- a/apps/provisioning_api/lib/Controller/AppConfigController.php +++ b/apps/provisioning_api/lib/Controller/AppConfigController.php @@ -153,7 +153,7 @@ class AppConfigController extends OCSController { throw new \InvalidArgumentException('The given key can not be set'); } - if ($app === 'core' && (strpos($key, 'public_') === 0 || strpos($key, 'remote_') === 0)) { + if ($app === 'core' && ($key === 'encryption_enabled' || strpos($key, 'public_') === 0 || strpos($key, 'remote_') === 0)) { throw new \InvalidArgumentException('The given key can not be set'); } } |