MediaWiki REL1_34
|
Public Member Functions | |
__construct (array $conditions=null, array $params=[]) | |
clear ( $username=null, $ip=null) | |
Clear the throttle counter. | |
increase ( $username=null, $ip=null, $caller=null) | |
Increase the throttle counter and return whether the attempt should be throttled. | |
setLogger (LoggerInterface $logger) | |
Protected Member Functions | |
logRejection (array $context) | |
Static Protected Member Functions | |
static | normalizeThrottleConditions ( $throttleConditions) |
Handles B/C for $wgPasswordAttemptThrottle. | |
Protected Attributes | |
BagOStuff | $cache |
array[] | $conditions |
See documentation of $wgPasswordAttemptThrottle for format. | |
LoggerInterface | $logger |
string | $type |
int float | $warningLimit |
Definition at line 37 of file Throttler.php.
MediaWiki\Auth\Throttler::__construct | ( | array | $conditions = null, |
array | $params = [] ) |
array | null | $conditions | An array of arrays describing throttling conditions. Defaults to $wgPasswordAttemptThrottle. See documentation of that variable for format. |
array | $params | Parameters (all optional):
|
Definition at line 63 of file Throttler.php.
References MediaWiki\Auth\Throttler\$conditions, MediaWiki\MediaWikiServices\getInstance(), and MediaWiki\Auth\Throttler\setLogger().
MediaWiki\Auth\Throttler::clear | ( | $username = null, | |
$ip = null ) |
Clear the throttle counter.
Should be called after a successful authentication attempt.
string | null | $username | |
string | null | $ip |
\MWException
Definition at line 170 of file Throttler.php.
MediaWiki\Auth\Throttler::increase | ( | $username = null, | |
$ip = null, | |||
$caller = null ) |
Increase the throttle counter and return whether the attempt should be throttled.
Should be called before an authentication attempt.
string | null | $username | |
string | null | $ip | |
string | null | $caller | The authentication method from which we were called. |
Definition at line 113 of file Throttler.php.
References MediaWiki\Auth\Throttler\logRejection().
|
protected |
Definition at line 195 of file Throttler.php.
References $context.
Referenced by MediaWiki\Auth\Throttler\increase().
|
staticprotected |
Handles B/C for $wgPasswordAttemptThrottle.
array | $throttleConditions |
Definition at line 185 of file Throttler.php.
MediaWiki\Auth\Throttler::setLogger | ( | LoggerInterface | $logger | ) |
Definition at line 95 of file Throttler.php.
References MediaWiki\Auth\Throttler\$logger.
Referenced by MediaWiki\Auth\Throttler\__construct().
|
protected |
Definition at line 48 of file Throttler.php.
|
protected |
See documentation of $wgPasswordAttemptThrottle for format.
Old (pre-1.27) format is not allowed here.
Definition at line 46 of file Throttler.php.
Referenced by MediaWiki\Auth\Throttler\__construct().
|
protected |
Definition at line 50 of file Throttler.php.
Referenced by MediaWiki\Auth\Throttler\setLogger().
|
protected |
Definition at line 39 of file Throttler.php.
|
protected |
Definition at line 52 of file Throttler.php.