ILIAS  release_8 Revision v8.19-1-g4e8f2f9140c
All Data Structures Namespaces Files Functions Variables Modules Pages
ilCtrlToken Class Reference

Class ilCtrlToken is responsible for generating and storing unique CSRF tokens. More...

+ Inheritance diagram for ilCtrlToken:
+ Collaboration diagram for ilCtrlToken:

Public Member Functions

 __construct (string $token)
 ilCtrlToken Constructor More...
 
 verifyWith (string $token)
 
 getToken ()
 

Private Attributes

string $token
 

Detailed Description

Class ilCtrlToken is responsible for generating and storing unique CSRF tokens.

Author
Thibeau Fuhrer thf@s.nosp@m.tude.nosp@m.r-rai.nosp@m.mann.nosp@m..ch

Definition at line 13 of file class.ilCtrlToken.php.

Constructor & Destructor Documentation

◆ __construct()

ilCtrlToken::__construct ( string  $token)

ilCtrlToken Constructor

Parameters
string$token

Definition at line 27 of file class.ilCtrlToken.php.

References $token.

28  {
29  $this->token = $token;
30  }

Member Function Documentation

◆ getToken()

ilCtrlToken::getToken ( )

Implements ilCtrlTokenInterface.

Definition at line 43 of file class.ilCtrlToken.php.

References $token.

43  : string
44  {
45  return $this->token;
46  }

◆ verifyWith()

ilCtrlToken::verifyWith ( string  $token)

Implements ilCtrlTokenInterface.

Definition at line 35 of file class.ilCtrlToken.php.

35  : bool
36  {
37  return ($this->token === $token);
38  }

Field Documentation

◆ $token

string ilCtrlToken::$token
private

Definition at line 20 of file class.ilCtrlToken.php.

Referenced by __construct(), and getToken().


The documentation for this class was generated from the following file: