- intercept requests before authentication
- DokuWiki's own login
This Event allows to provide authentication on a per request basis by using signatures or tokens instead of the default DokuWiki login or cookies. The event is triggered by auth_setup() in inc/auth.php and by login() in inc/RemoteAPICore.php.
Since 2010-01-29, there is an
AFTER event available.
The global $AUTH_ACL is not set up when this event is triggered.
The passed Doku_Event object has the fields:
$data is an associative array containing the login parameters as entries:
user– User name
sticky– Cookie should not expire
silent– Don't show error on bad authentication
If the BEFORE event handler does not
$event->preventDefault() those parameters are passed to auth_login() via a wrapper function. The parameters in the
$data field can be modified here as well.
$result field is set by the default function to true on successful authentication, otherwise false.
The AFTER event handler can changes this return value, but the default login action is then already tried.