diff options
author | Julius Härtl <jus@bitgrid.net> | 2020-09-25 12:03:55 +0200 |
---|---|---|
committer | Julius Härtl <jus@bitgrid.net> | 2020-12-14 11:12:50 +0100 |
commit | 934f8a17f9e5f373be59fdf88d1303d8e89eb487 (patch) | |
tree | fc5b406b0fcf29b88b95f1a28aec1f37eaddcfc1 /lib/private | |
parent | 7f1f8963e4cf32e9c51d5db4a133dada6e3c6c91 (diff) | |
download | nextcloud-server-934f8a17f9e5f373be59fdf88d1303d8e89eb487.tar.gz nextcloud-server-934f8a17f9e5f373be59fdf88d1303d8e89eb487.zip |
Avoid checking for brute force protection capabilities when upgrading
This might happen a releases that doesn't have this table yet
Signed-off-by: Julius Härtl <jus@bitgrid.net>
Diffstat (limited to 'lib/private')
-rw-r--r-- | lib/private/Security/Bruteforce/Capabilities.php | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/private/Security/Bruteforce/Capabilities.php b/lib/private/Security/Bruteforce/Capabilities.php index eab55db1c90..fcf05efbd7e 100644 --- a/lib/private/Security/Bruteforce/Capabilities.php +++ b/lib/private/Security/Bruteforce/Capabilities.php @@ -46,6 +46,10 @@ class Capabilities implements IPublicCapability { } public function getCapabilities() { + if (version_compare(\OC::$server->getConfig()->getSystemValue('version', '0.0.0.0'), '12.0.0.0', '<')) { + return []; + } + return [ 'bruteforce' => [ 'delay' => $this->throttler->getDelay($this->request->getRemoteAddress()) |