‪TYPO3CMS  11.5
TYPO3\CMS\FrontendLogin\Controller\PasswordRecoveryController Class Reference
Inheritance diagram for TYPO3\CMS\FrontendLogin\Controller\PasswordRecoveryController:
TYPO3\CMS\FrontendLogin\Controller\AbstractLoginFormController TYPO3\CMS\Extbase\Mvc\Controller\ActionController TYPO3\CMS\Extbase\Mvc\Controller\ControllerInterface

Public Member Functions

 __construct (EventDispatcherInterface $eventDispatcher, RecoveryServiceInterface $recoveryService, FrontendUserRepository $userRepository)
 
ResponseInterface void recoveryAction (string $userIdentifier=null)
 
 showChangePasswordAction (string $hash='')
 
 validateHashAndPasswords ()
 
ResponseInterface string ForwardResponse null changePasswordAction (string $newPass, string $hash)
 
- ‪Public Member Functions inherited from ‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController
 injectResponseFactory (ResponseFactoryInterface $responseFactory)
 
 injectStreamFactory (StreamFactoryInterface $streamFactory)
 
 injectConfigurationManager (ConfigurationManagerInterface $configurationManager)
 
 injectObjectManager (ObjectManagerInterface $objectManager)
 
 injectSignalSlotDispatcher (Dispatcher $signalSlotDispatcher)
 
 injectValidatorResolver (ValidatorResolver $validatorResolver)
 
 injectViewResolver (ViewResolverInterface $viewResolver)
 
 injectReflectionService (ReflectionService $reflectionService)
 
 injectHashService (HashService $hashService)
 
 injectMvcPropertyMappingConfigurationService (MvcPropertyMappingConfigurationService $mvcPropertyMappingConfigurationService)
 
 injectEventDispatcher (EventDispatcherInterface $eventDispatcher)
 
 injectPropertyMapper (PropertyMapper $propertyMapper)
 
 injectInternalFlashMessageService (FlashMessageService $flashMessageService)
 
 injectInternalExtensionService (ExtensionService $extensionService)
 
 initializeControllerArgumentsBaseValidators ()
 
ResponseInterface processRequest (RequestInterface $request)
 
ControllerContext getControllerContext ()
 
 addFlashMessage ($messageBody, $messageTitle='', $severity=AbstractMessage::OK, $storeInSession=true)
 
never forward ($actionName, $controllerName=null, $extensionName=null, array $arguments=null)
 
never throwStatus ($statusCode, $statusMessage=null, $content=null)
 

Protected Member Functions

 validateIfHashHasExpired ()
 
 validateNewPassword (Result $originalResult)
 
 getTranslation (string $key)
 
bool hasValidHash ($hash)
 
ForwardResponse string notifyPasswordChange (string $newPassword, string $hashedPassword, string $hash)
 
 exposeNoneExistentUser (?string $email)
 
 invalidateUserSessions (int $userId)
 
- ‪Protected Member Functions inherited from ‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController
 initializeView (ViewInterface $view)
 
 initializeAction ()
 
 initializeActionMethodArguments ()
 
 initializeActionMethodValidators ()
 
 renderAssetsForRequest ($request)
 
string resolveActionMethodName ()
 
 callActionMethod (RequestInterface $request)
 
ViewInterface resolveView ()
 
 setViewConfiguration (ViewInterface $view)
 
array getViewProperty ($extbaseFrameworkConfiguration, $setting)
 
ResponseInterface errorAction ()
 
 addErrorFlashMessage ()
 
string bool getErrorFlashMessage ()
 
ResponseInterface null forwardToReferringRequest ()
 
string getFlattenedValidationErrorMessage ()
 
 getFlashMessageQueue (string $identifier=null)
 
ControllerContext buildControllerContext ()
 
never redirect ($actionName, $controllerName=null, $extensionName=null, array $arguments=null, $pageUid=null, $_=null, $statusCode=303)
 
never redirectToUri ($uri, $_=null, $statusCode=303)
 
string addBaseUriIfNecessary ($uri)
 
 mapRequestArgumentsToControllerArguments ()
 
ResponseInterface htmlResponse (string $html=null)
 
ResponseInterface jsonResponse (string $json=null)
 

Protected Attributes

RecoveryServiceInterface $recoveryService
 
FrontendUserRepository $userRepository
 
EventDispatcherInterface $eventDispatcher
 
- ‪Protected Attributes inherited from ‪TYPO3\CMS\Extbase\Mvc\Controller\ActionController
ResponseFactoryInterface $responseFactory
 
StreamFactoryInterface $streamFactory
 
TYPO3 CMS Extbase Reflection ReflectionService $reflectionService
 
HashService $hashService
 
ViewInterface $view
 
string $defaultViewObjectName = TemplateView::class
 
string $actionMethodName = 'indexAction'
 
string $errorMethodName = 'errorAction'
 
TYPO3 CMS Extbase Mvc Controller MvcPropertyMappingConfigurationService $mvcPropertyMappingConfigurationService
 
EventDispatcherInterface $eventDispatcher
 
Request $request
 
TYPO3 CMS Extbase SignalSlot Dispatcher $signalSlotDispatcher
 
ObjectManagerInterface $objectManager
 
TYPO3 CMS Extbase Mvc Web Routing UriBuilder $uriBuilder
 
array $settings
 
TYPO3 CMS Extbase Validation ValidatorResolver $validatorResolver
 
TYPO3 CMS Extbase Mvc Controller Arguments $arguments
 
ControllerContext $controllerContext
 
ConfigurationManagerInterface $configurationManager
 

Detailed Description

this is a concrete TYPO3 implementation and solely used for EXT:felogin and not part of TYPO3's Core API.

Definition at line 43 of file PasswordRecoveryController.php.

Constructor & Destructor Documentation

◆ __construct()

TYPO3\CMS\FrontendLogin\Controller\PasswordRecoveryController::__construct ( EventDispatcherInterface  $eventDispatcher,
RecoveryServiceInterface  $recoveryService,
FrontendUserRepository  $userRepository 
)

Member Function Documentation

◆ changePasswordAction()

ResponseInterface string ForwardResponse null TYPO3\CMS\FrontendLogin\Controller\PasswordRecoveryController::changePasswordAction ( string  $newPass,
string  $hash 
)

◆ exposeNoneExistentUser()

TYPO3\CMS\FrontendLogin\Controller\PasswordRecoveryController::exposeNoneExistentUser ( ?string  $email)
protected

Returns whether the exposeNonexistentUserInForgotPasswordDialog setting is active or not

Definition at line 324 of file PasswordRecoveryController.php.

Referenced by TYPO3\CMS\FrontendLogin\Controller\PasswordRecoveryController\recoveryAction().

◆ getTranslation()

◆ hasValidHash()

bool TYPO3\CMS\FrontendLogin\Controller\PasswordRecoveryController::hasValidHash (   $hash)
protected

Validates that $hash is in the expected format (timestamp|forgot_hash)

Parameters
string$hash
Returns
‪bool

Definition at line 278 of file PasswordRecoveryController.php.

Referenced by TYPO3\CMS\FrontendLogin\Controller\PasswordRecoveryController\validateIfHashHasExpired().

◆ invalidateUserSessions()

TYPO3\CMS\FrontendLogin\Controller\PasswordRecoveryController::invalidateUserSessions ( int  $userId)
protected

Invalidate all frontend user sessions by given user id

Definition at line 338 of file PasswordRecoveryController.php.

Referenced by TYPO3\CMS\FrontendLogin\Controller\PasswordRecoveryController\changePasswordAction().

◆ notifyPasswordChange()

ForwardResponse string TYPO3\CMS\FrontendLogin\Controller\PasswordRecoveryController::notifyPasswordChange ( string  $newPassword,
string  $hashedPassword,
string  $hash 
)
protected
Parameters
string$newPassword‪Unencrypted new password
string$hashedPassword‪New password hash passed as reference
string$hash‪Forgot password hash
Returns
‪ForwardResponse|string

Definition at line 289 of file PasswordRecoveryController.php.

Referenced by TYPO3\CMS\FrontendLogin\Controller\PasswordRecoveryController\changePasswordAction().

◆ recoveryAction()

ResponseInterface void TYPO3\CMS\FrontendLogin\Controller\PasswordRecoveryController::recoveryAction ( string  $userIdentifier = null)

◆ showChangePasswordAction()

TYPO3\CMS\FrontendLogin\Controller\PasswordRecoveryController::showChangePasswordAction ( string  $hash = '')

◆ validateHashAndPasswords()

TYPO3\CMS\FrontendLogin\Controller\PasswordRecoveryController::validateHashAndPasswords ( )

Validate entered password and passwordRepeat values. If they are invalid a forward() to showChangePasswordAction() takes place. All validation errors are put into the request mapping results.

Used validators are configured via TypoScript settings.

Exceptions
NoSuchArgumentException
StopActionException
Todo:
‪: Refactor all password checks to validators

Definition at line 159 of file PasswordRecoveryController.php.

References TYPO3\CMS\FrontendLogin\Controller\PasswordRecoveryController\getTranslation(), TYPO3\CMS\FrontendLogin\Controller\PasswordRecoveryController\validateIfHashHasExpired(), and TYPO3\CMS\FrontendLogin\Controller\PasswordRecoveryController\validateNewPassword().

Referenced by TYPO3\CMS\FrontendLogin\Controller\PasswordRecoveryController\changePasswordAction().

◆ validateIfHashHasExpired()

TYPO3\CMS\FrontendLogin\Controller\PasswordRecoveryController::validateIfHashHasExpired ( )
protected

◆ validateNewPassword()

TYPO3\CMS\FrontendLogin\Controller\PasswordRecoveryController::validateNewPassword ( Result  $originalResult)
protected

Member Data Documentation

◆ $eventDispatcher

EventDispatcherInterface TYPO3\CMS\FrontendLogin\Controller\PasswordRecoveryController::$eventDispatcher
protected

◆ $recoveryService

RecoveryServiceInterface TYPO3\CMS\FrontendLogin\Controller\PasswordRecoveryController::$recoveryService
protected

◆ $userRepository

FrontendUserRepository TYPO3\CMS\FrontendLogin\Controller\PasswordRecoveryController::$userRepository
protected