MediaWiki
1.32.5
|
Check if the user is blocked, and prevent authentication if so. More...
Public Member Functions | |
__construct ( $params=[]) | |
beginSecondaryAccountCreation ( $user, $creator, array $reqs) | |
Start an account creation flow. More... | |
beginSecondaryAuthentication ( $user, array $reqs) | |
Start an authentication flow. More... | |
getAuthenticationRequests ( $action, array $options) | |
Return the applicable list of AuthenticationRequests. More... | |
setConfig (Config $config) | |
Set configuration. More... | |
testUserForCreation ( $user, $autocreate, array $options=[]) | |
Determine whether an account may be created. More... | |
Public Member Functions inherited from MediaWiki\Auth\AbstractSecondaryAuthenticationProvider | |
autoCreatedAccount ( $user, $source) | |
Post-auto-creation callback. More... | |
continueSecondaryAccountCreation ( $user, $creator, array $reqs) | |
Continue an authentication flow. More... | |
continueSecondaryAuthentication ( $user, array $reqs) | |
Continue an authentication flow. More... | |
postAccountCreation ( $user, $creator, AuthenticationResponse $response) | |
Post-creation callback. More... | |
postAuthentication ( $user, AuthenticationResponse $response) | |
Post-login callback. More... | |
providerAllowsAuthenticationDataChange (AuthenticationRequest $req, $checkData=true) | |
Validate a change of authentication data (e.g. More... | |
providerAllowsPropertyChange ( $property) | |
Determine whether a property can change. More... | |
providerChangeAuthenticationData (AuthenticationRequest $req) | |
Change or remove authentication data (e.g. More... | |
providerRevokeAccessForUser ( $username) | |
@inheritDoc More... | |
testForAccountCreation ( $user, $creator, array $reqs) | |
Determine whether an account creation may begin. More... | |
Public Member Functions inherited from MediaWiki\Auth\AbstractAuthenticationProvider | |
getUniqueId () | |
@inheritDoc More... | |
setLogger (LoggerInterface $logger) | |
setManager (AuthManager $manager) | |
Set AuthManager. More... | |
Protected Attributes | |
bool | $blockDisablesLogin = null |
Protected Attributes inherited from MediaWiki\Auth\AbstractAuthenticationProvider | |
Config | $config |
LoggerInterface | $logger |
AuthManager | $manager |
Check if the user is blocked, and prevent authentication if so.
Definition at line 33 of file CheckBlocksSecondaryAuthenticationProvider.php.
MediaWiki\Auth\CheckBlocksSecondaryAuthenticationProvider::__construct | ( | $params = [] | ) |
array | $params |
|
Definition at line 43 of file CheckBlocksSecondaryAuthenticationProvider.php.
References $params.
MediaWiki\Auth\CheckBlocksSecondaryAuthenticationProvider::beginSecondaryAccountCreation | ( | $user, | |
$creator, | |||
array | $reqs | ||
) |
Start an account creation flow.
User | $user | User being created (has been added to the database). This may become a "UserValue" in the future, or User may be refactored into such. |
User | $creator | User doing the creation. This may become a "UserValue" in the future, or User may be refactored into such. |
AuthenticationRequest[] | $reqs |
Implements MediaWiki\Auth\SecondaryAuthenticationProvider.
Definition at line 73 of file CheckBlocksSecondaryAuthenticationProvider.php.
References MediaWiki\Auth\AuthenticationResponse\newAbstain().
MediaWiki\Auth\CheckBlocksSecondaryAuthenticationProvider::beginSecondaryAuthentication | ( | $user, | |
array | $reqs | ||
) |
Start an authentication flow.
Note that this may be called for a user even if beginSecondaryAccountCreation() was never called. The module should take the opportunity to do any necessary setup in that case.
User | $user | User being authenticated. This may become a "UserValue" in the future, or User may be refactored into such. |
AuthenticationRequest[] | $reqs |
Implements MediaWiki\Auth\SecondaryAuthenticationProvider.
Definition at line 61 of file CheckBlocksSecondaryAuthenticationProvider.php.
References $user, MediaWiki\Auth\AuthenticationResponse\newAbstain(), MediaWiki\Auth\AuthenticationResponse\newFail(), and MediaWiki\Auth\AuthenticationResponse\newPass().
MediaWiki\Auth\CheckBlocksSecondaryAuthenticationProvider::getAuthenticationRequests | ( | $action, | |
array | $options | ||
) |
Return the applicable list of AuthenticationRequests.
Possible values for $action depend on whether the implementing class is also a PreAuthenticationProvider, PrimaryAuthenticationProvider, or SecondaryAuthenticationProvider.
string | $action | |
array | $options | Options are:
|
Implements MediaWiki\Auth\AuthenticationProvider.
Definition at line 57 of file CheckBlocksSecondaryAuthenticationProvider.php.
MediaWiki\Auth\CheckBlocksSecondaryAuthenticationProvider::setConfig | ( | Config | $config | ) |
Set configuration.
Config | $config |
Reimplemented from MediaWiki\Auth\AbstractAuthenticationProvider.
Definition at line 49 of file CheckBlocksSecondaryAuthenticationProvider.php.
References MediaWiki\Auth\AbstractAuthenticationProvider\$config.
MediaWiki\Auth\CheckBlocksSecondaryAuthenticationProvider::testUserForCreation | ( | $user, | |
$autocreate, | |||
array | $options = [] |
||
) |
Determine whether an account may be created.
User | $user | User being created (not added to the database yet). This may become a "UserValue" in the future, or User may be refactored into such. |
bool | string | $autocreate | False if this is not an auto-creation, or the source of the auto-creation passed to AuthManager::autoCreateUser(). |
array | $options |
|
Reimplemented from MediaWiki\Auth\AbstractSecondaryAuthenticationProvider.
Definition at line 77 of file CheckBlocksSecondaryAuthenticationProvider.php.
References $user, RequestContext\getMain(), StatusValue\newFatal(), StatusValue\newGood(), and Block\TYPE_RANGE.
|
protected |
Definition at line 36 of file CheckBlocksSecondaryAuthenticationProvider.php.