MediaWiki
master
LoggedOutEditToken.php
Go to the documentation of this file.
1
<?php
24
namespace
MediaWiki\User
;
25
26
use
MediaWiki\Session\Token
;
27
39
class
LoggedOutEditToken
extends
Token
{
40
44
public
function
__construct
() {
45
parent::__construct(
''
,
''
,
false
);
46
}
47
48
protected
function
toStringAtTimestamp
( $timestamp ) {
49
return
self::SUFFIX
;
50
}
51
52
public
function
match
( $userToken, $maxAge =
null
) {
53
return
$userToken ===
self::SUFFIX
;
54
}
55
}
56
58
class_alias( LoggedOutEditToken::class,
'LoggedOutEditToken'
);
MediaWiki\Session\Token
Value object representing a CSRF token.
Definition
Token.php:34
MediaWiki\Session\Token\SUFFIX
const SUFFIX
CSRF token suffix.
Definition
Token.php:38
MediaWiki\User\LoggedOutEditToken
Value object representing a logged-out user's edit token.
Definition
LoggedOutEditToken.php:39
MediaWiki\User\LoggedOutEditToken\match
match( $userToken, $maxAge=null)
Test if the token-string matches this token.
Definition
LoggedOutEditToken.php:52
MediaWiki\User\LoggedOutEditToken\__construct
__construct()
Definition
LoggedOutEditToken.php:44
MediaWiki\User\LoggedOutEditToken\toStringAtTimestamp
toStringAtTimestamp( $timestamp)
Get the string representation of the token at a timestamp.
Definition
LoggedOutEditToken.php:48
MediaWiki\User
Utility class for bot passwords.
Definition
ActorCache.php:21
includes
user
LoggedOutEditToken.php
Generated on Tue Dec 3 2024 15:26:45 for MediaWiki by
1.10.0