TYPO3 CMS  TYPO3_7-6
TYPO3\CMS\Backend\AjaxLoginHandler Class Reference

Public Member Functions

 loginAction (ServerRequestInterface $request, ResponseInterface $response)
 
 logoutAction (ServerRequestInterface $request, ResponseInterface $response)
 
 refreshAction (ServerRequestInterface $request, ResponseInterface $response)
 
 isTimedOutAction (ServerRequestInterface $request, ResponseInterface $response)
 

Protected Member Functions

 isAuthorizedBackendSession ()
 
 hasLoginBeenProcessed ()
 
 getBackendUser ()
 

Detailed Description

This is the ajax handler for backend login after timeout.

Definition at line 24 of file AjaxLoginHandler.php.

Member Function Documentation

◆ getBackendUser()

◆ hasLoginBeenProcessed()

TYPO3\CMS\Backend\AjaxLoginHandler::hasLoginBeenProcessed ( )
protected

Check whether the user was already authorized or not

Returns
bool

Definition at line 140 of file AjaxLoginHandler.php.

References TYPO3\CMS\Backend\AjaxLoginHandler\getBackendUser().

Referenced by TYPO3\CMS\Backend\AjaxLoginHandler\loginAction().

◆ isAuthorizedBackendSession()

TYPO3\CMS\Backend\AjaxLoginHandler::isAuthorizedBackendSession ( )
protected

Checks if a user is logged in and the session is active.

Returns
bool

Definition at line 129 of file AjaxLoginHandler.php.

References TYPO3\CMS\Backend\AjaxLoginHandler\getBackendUser().

Referenced by TYPO3\CMS\Backend\AjaxLoginHandler\loginAction().

◆ isTimedOutAction()

TYPO3\CMS\Backend\AjaxLoginHandler::isTimedOutAction ( ServerRequestInterface  $request,
ResponseInterface  $response 
)

Checks if the user session is expired yet

Parameters
ServerRequestInterface$request
ResponseInterface$response
Returns
ResponseInterface

Definition at line 100 of file AjaxLoginHandler.php.

References $GLOBALS, and TYPO3\CMS\Backend\AjaxLoginHandler\getBackendUser().

◆ loginAction()

TYPO3\CMS\Backend\AjaxLoginHandler::loginAction ( ServerRequestInterface  $request,
ResponseInterface  $response 
)

Handles the actual login process, more specifically it defines the response. The login details were sent in as part of the ajax request and automatically logged in the user inside the TYPO3 CMS bootstrap part of the ajax call. If that was successful, we have a BE user and reset the timer and hide the login window. If it was unsuccessful, we display that and show the login box again.

Parameters
ServerRequestInterface$request
ResponseInterface$response
Returns
ResponseInterface

Definition at line 37 of file AjaxLoginHandler.php.

References TYPO3\CMS\Core\FormProtection\FormProtectionFactory\get(), TYPO3\CMS\Backend\AjaxLoginHandler\hasLoginBeenProcessed(), and TYPO3\CMS\Backend\AjaxLoginHandler\isAuthorizedBackendSession().

◆ logoutAction()

TYPO3\CMS\Backend\AjaxLoginHandler::logoutAction ( ServerRequestInterface  $request,
ResponseInterface  $response 
)

Logs out the current BE user

Parameters
ServerRequestInterface$request
ResponseInterface$response
Returns
ResponseInterface

Definition at line 61 of file AjaxLoginHandler.php.

References TYPO3\CMS\Backend\AjaxLoginHandler\getBackendUser().

◆ refreshAction()

TYPO3\CMS\Backend\AjaxLoginHandler::refreshAction ( ServerRequestInterface  $request,
ResponseInterface  $response 
)

Refreshes the login without needing login information. We just refresh the session.

Parameters
ServerRequestInterface$request
ResponseInterface$response
Returns
ResponseInterface

Definition at line 81 of file AjaxLoginHandler.php.

References TYPO3\CMS\Backend\AjaxLoginHandler\getBackendUser().