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-09 12:13:33 +0100 |
commit | f5501ca2764caae5c0f53949c47ded4ba8ad3c17 (patch) | |
tree | da8c411125464223c1cdc91b4a1bdb138bae33ba /lib | |
parent | 83f4f480ab72c6e90545f0529c5ad1c7d2090f2f (diff) | |
download | nextcloud-server-f5501ca2764caae5c0f53949c47ded4ba8ad3c17.tar.gz nextcloud-server-f5501ca2764caae5c0f53949c47ded4ba8ad3c17.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')
-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()) |