Extension:CentralAuth/Hooks/CentralAuthLoginRedirectData
Appearance
CentralAuthLoginRedirectData | |
---|---|
Available from version ??? This hook is called after a user has logged in to a single wiki during the login process, when saving any required data to the token store before redirecting to the login wiki. |
|
Define function: | public static function onCentralAuthLoginRedirectData( CentralAuthUser $centralUser, array &$data ) { ... }
|
Attach hook: | $wgHooks['CentralAuthLoginRedirectData'][] = 'MyExtensionHooks::onCentralAuthLoginRedirectData';
|
Called from: | File(s): CentralAuth / includes/CentralAuthHooks.php Function(s): doCentralLoginRedirect |
For more information about attaching hooks, see Manual:Hooks .
For examples of other extensions using this hook, see Category:CentralAuthLoginRedirectData extensions.
Parameters
[edit]$centralUser
: An instance ofCentralAuthUser
$data
: An associativearray
of data, containing the following keys:'secret'
: Astring
of random data generated byMWCryptRand::generateHex()
'name'
: Astring
representing the name of the central user (filled in byCentralAuthUser::getName()
)'guid'
: Aint
representing the global user ID of the central user (filled in byCentralAuthUser::getId()
)'wikiId'
: Astring
representing an ASCII string identifier of the wiki (filled in bywfWikiID()
)'secureCookies'
: Abool
representing whether cookies are secure or not'finalProto'
: Astring
representing the final protocol of the page, either'http'
or'https'
'currentProto'
: Astring
representing the current protocol of the page, either'http'
or'https'