Localisation updates from https://translatewiki.net.
[mediawiki.git] / includes / session / Hook / SessionCheckInfoHook.php
blobf54c2f12fa18a0c903e30581e09ff7b7249e7b9e
1 <?php
3 namespace MediaWiki\Session\Hook;
5 use MediaWiki\Request\WebRequest;
6 use MediaWiki\Session\SessionInfo;
8 /**
9 * This is a hook handler interface, see docs/Hooks.md.
10 * Use the hook name "SessionCheckInfo" to register handlers implementing this interface.
12 * @stable to implement
13 * @ingroup Hooks
15 interface SessionCheckInfoHook {
16 /**
17 * Use this hook to validate a MediaWiki\Session\SessionInfo as it's being
18 * loaded from storage.
20 * @since 1.35
22 * @param string &$reason Rejection reason to be logged
23 * @param SessionInfo $info MediaWiki\Session\SessionInfo being validated
24 * @param WebRequest $request WebRequest being loaded from
25 * @param array|bool $metadata Metadata array for the MediaWiki\Session\Session
26 * @param array|bool $data Data array for the MediaWiki\Session\Session
27 * @return bool|void True or no return value to continue, or false to prevent
28 * the MediaWiki\Session\SessionInfo from being used
30 public function onSessionCheckInfo( &$reason, $info, $request, $metadata,
31 $data