wgRateLimits: Add configuration option to ignore 'noratelimit' right
authorBryan Davis <bd808@wikimedia.org>
Tue, 4 Oct 2016 04:46:30 +0000 (22:46 -0600)
committerBryanDavis <bdavis@wikimedia.org>
Tue, 4 Oct 2016 05:38:10 +0000 (05:38 +0000)
commitbc6e4d008216411958f285c831cb557a0804dd00
tree03f80ed1f2ffb937d7b24f824b17c70f730007b5
parent2cbff048de38da72ce55a20aa5f1afbbfa745a14
wgRateLimits: Add configuration option to ignore 'noratelimit' right

It may be reasonable to ignore the 'noratelimit' right granted to a user
when perfuming some rate limit checks. As an example, a rate limit check
on failed authentication attempts should not be bypassed.

Add an optional '&can-bypass' configuration option for each
$wgRateLimits action that can be set to false to disable checking
User::isPingLimitable(). This bypasses both 'noratelimit' and
$wgRateLimitsExcludedIPs exclusions.

Depends-On: Iacdd1719d5f08eca91de0a35c0042ffee2136f34
Change-Id: Ia3add8bbbab0307f036e9b77e752c382da3a0d04
includes/DefaultSettings.php
includes/user/User.php