summaryrefslogtreecommitdiffstats
path: root/apps/files/appinfo
diff options
context:
space:
mode:
authorLukas Reschke <lukas@owncloud.com>2015-04-16 22:39:44 +0200
committerLukas Reschke <lukas@owncloud.com>2015-04-20 11:12:17 +0200
commit4ea205e2629455d908a30367d5f42f9d07c1fd45 (patch)
tree4c83f259c527a2726405b7b14aa0501c2393f9cc /apps/files/appinfo
parent9cb260d310de5bed546531eff5fbf0b7518f0f2f (diff)
downloadnextcloud-server-4ea205e2629455d908a30367d5f42f9d07c1fd45.tar.gz
nextcloud-server-4ea205e2629455d908a30367d5f42f9d07c1fd45.zip
Block old legacy clients
This Pull Request introduces a SabreDAV plugin that will block all older clients than 1.6.1 to connect and sync with the ownCloud instance. This has multiple reasons: 1. Old ownCloud client versions before 1.6.0 are not properly working with sticky cookies for load balancers and thus generating sessions en masse 2. Old ownCloud client versions tend to be horrible buggy In some cases we had in 80minutes about 10'000 sessions created by a single user. While this change set does not really "fix" the problem as 3rdparty legacy clients are affected as well, it is a good work-around and hopefully should force users to update their client
Diffstat (limited to 'apps/files/appinfo')
-rw-r--r--apps/files/appinfo/remote.php1
1 files changed, 1 insertions, 0 deletions
diff --git a/apps/files/appinfo/remote.php b/apps/files/appinfo/remote.php
index 1e54fc10efa..b8dc68f1f81 100644
--- a/apps/files/appinfo/remote.php
+++ b/apps/files/appinfo/remote.php
@@ -43,6 +43,7 @@ $server->setBaseUri($baseuri);
// Load plugins
$defaults = new OC_Defaults();
+$server->addPlugin(new \OC\Connector\Sabre\BlockLegacyClientPlugin(\OC::$server->getConfig()));
$server->addPlugin(new \Sabre\DAV\Auth\Plugin($authBackend, $defaults->getName()));
// FIXME: The following line is a workaround for legacy components relying on being able to send a GET to /
$server->addPlugin(new \OC\Connector\Sabre\DummyGetResponsePlugin());