diff options
author | Lukas Reschke <lukas@owncloud.com> | 2014-11-03 10:55:52 +0100 |
---|---|---|
committer | Lukas Reschke <lukas@owncloud.com> | 2014-11-03 16:53:03 +0100 |
commit | e73ccbd4cade0622615ee133496a571ac1d6dba7 (patch) | |
tree | 114c981b1ae7ae1e050dbfe74c1333b238a2b178 /settings/ajax | |
parent | f8f38b06dfef0af2555124cf0d1ec55402aa8c8c (diff) | |
download | nextcloud-server-e73ccbd4cade0622615ee133496a571ac1d6dba7.tar.gz nextcloud-server-e73ccbd4cade0622615ee133496a571ac1d6dba7.zip |
Migrate "setsecurity.php" to the AppFramework
Add switch to enforce SSL for subdomains
Add unit tests
Add test for boolean values
Camel-case
Fix ugly JS
Diffstat (limited to 'settings/ajax')
-rw-r--r-- | settings/ajax/setsecurity.php | 21 |
1 files changed, 0 insertions, 21 deletions
diff --git a/settings/ajax/setsecurity.php b/settings/ajax/setsecurity.php deleted file mode 100644 index f1f737a4943..00000000000 --- a/settings/ajax/setsecurity.php +++ /dev/null @@ -1,21 +0,0 @@ -<?php -/** - * Copyright (c) 2013-2014, Lukas Reschke <lukas@owncloud.com> - * This file is licensed under the Affero General Public License version 3 or later. - * See the COPYING-README file. - */ - -OC_Util::checkAdminUser(); -OCP\JSON::callCheck(); - -if(isset($_POST['enforceHTTPS'])) { - \OC::$server->getConfig()->setSystemValue('forcessl', filter_var($_POST['enforceHTTPS'], FILTER_VALIDATE_BOOLEAN)); -} - -if(isset($_POST['trustedDomain'])) { - $trustedDomains = \OC::$server->getConfig()->getSystemValue('trusted_domains'); - $trustedDomains[] = $_POST['trustedDomain']; - \OC::$server->getConfig()->setSystemValue('trusted_domains', $trustedDomains); -} - -echo 'true'; |