Manual:Hooks/LoginAuthenticateAudit

From MediaWiki.org

Jump to: navigation, search
LoginAuthenticateAudit
Available from version 1.10.0
A login attempt for a valid user account either succeeded or failed. No return data is accepted; this hook is for auditing only.

*Define function:
function fnMyHook( $user, $password, $retval ) { ... }

*Attach hook:
$wgHooks['LoginAuthenticateAudit'][] = 'fnMyHook';
Called from: SpecialUserlogin.php

*For more information about attaching hooks, see Manual:Hooks.
*For examples of extensions using this hook, see Category:LoginAuthenticateAudit extensions.


[edit] Details

$user - The User object being authenticated against.
$password - The password being submitted and found wanting.
$retval - A LoginForm class constant with authenticateUserData() return value (SUCCESS, WRONG_PASS, etc).