MfaConfigurationController extends AbstractMfaController

Controller to configure MFA providers in the backend

Internal

This class is a specific Backend controller implementation and is not considered part of the Public TYPO3 API.

Table of Contents

Properties

$allowedActions  : array<string|int, mixed>
$allowedProviders  : array<string|int, mixed>
$iconFactory  : IconFactory
$mfaProviderRegistry  : MfaProviderRegistry
$mfaRequired  : bool
$mfaTsConfig  : array<string|int, mixed>
$moduleTemplate  : ModuleTemplate|null
$moduleTemplateFactory  : ModuleTemplateFactory
$uriBuilder  : UriBuilder

Methods

__construct()  : mixed
activateAction()  : ResponseInterface
Handle activate request, receiving from the setup view by forwarding the request to the appropriate provider.
deactivateAction()  : ResponseInterface
Handle deactivate request by forwarding the request to the appropriate provider. Also remove the provider as default provider from user UC, if set.
editAction()  : ResponseInterface
Render form to edit a provider by using provider specific content
handleRequest()  : ResponseInterface
Main entry point, checking prerequisite, initializing and setting up the view and finally dispatching to the requested action.
overviewAction()  : ResponseInterface
Setup the overview with all available MFA providers
saveAction()  : ResponseInterface
Handle save request, receiving from the edit view by forwarding the request to the appropriate provider.
setupAction()  : ResponseInterface
Render form to setup a provider by using provider specific content
unlockAction()  : ResponseInterface
Handle unlock request by forwarding the request to the appropriate provider
addFlashMessage()  : void
addFormButtons()  : void
addOverviewButtons()  : void
getActionUri()  : UriInterface
Build a uri for the current controller based on the given action, respecting additional parameters.
getBackendUser()  : BackendUserAuthentication
getDefaultProviderIdentifier()  : string
Get the default provider
getLanguageService()  : LanguageService
getRecommendedProvider()  : MfaProviderManifestInterface|null
Get the recommended provider
getRecommendedProviderIdentifier()  : string
Get the recommended provider
getReturnUrl()  : string
hasSuitableDefaultProviders()  : bool
Check if there are more suitable default providers for the current user
initializeMfaConfiguration()  : void
Initialize MFA configuration based on TSconfig and global configuration
initializeView()  : StandaloneView
Initialize the standalone view and set the template name
isActionAllowed()  : bool
isDefaultProvider()  : bool
isProviderAllowed()  : bool
isValidIdentifier()  : bool
removeDefaultProvider()  : void
setDefaultProvider()  : void

Properties

$allowedActions

protected array<string|int, mixed> $allowedActions = ['overview', 'setup', 'activate', 'deactivate', 'unlock', 'edit', 'save']

$allowedProviders

protected array<string|int, mixed> $allowedProviders

$mfaTsConfig

protected array<string|int, mixed> $mfaTsConfig

Methods

activateAction()

Handle activate request, receiving from the setup view by forwarding the request to the appropriate provider.

public activateAction(ServerRequestInterface $request, MfaProviderManifestInterface $mfaProvider) : ResponseInterface

Furthermore, add the provider as default provider in case it is the recommended provider for this user, or no default provider is yet defined the newly activated provider is allowed to be a default provider and there are no other providers which would suite as default provider.

Parameters
$request : ServerRequestInterface
$mfaProvider : MfaProviderManifestInterface
Return values
ResponseInterface

deactivateAction()

Handle deactivate request by forwarding the request to the appropriate provider. Also remove the provider as default provider from user UC, if set.

public deactivateAction(ServerRequestInterface $request, MfaProviderManifestInterface $mfaProvider) : ResponseInterface
Parameters
$request : ServerRequestInterface
$mfaProvider : MfaProviderManifestInterface
Return values
ResponseInterface

handleRequest()

Main entry point, checking prerequisite, initializing and setting up the view and finally dispatching to the requested action.

public handleRequest(ServerRequestInterface $request) : ResponseInterface
Parameters
$request : ServerRequestInterface
Return values
ResponseInterface

overviewAction()

Setup the overview with all available MFA providers

public overviewAction(ServerRequestInterface $request, StandaloneView $view) : ResponseInterface
Parameters
$request : ServerRequestInterface
$view : StandaloneView
Return values
ResponseInterface

saveAction()

Handle save request, receiving from the edit view by forwarding the request to the appropriate provider.

public saveAction(ServerRequestInterface $request, MfaProviderManifestInterface $mfaProvider) : ResponseInterface
Parameters
$request : ServerRequestInterface
$mfaProvider : MfaProviderManifestInterface
Return values
ResponseInterface

unlockAction()

Handle unlock request by forwarding the request to the appropriate provider

public unlockAction(ServerRequestInterface $request, MfaProviderManifestInterface $mfaProvider) : ResponseInterface
Parameters
$request : ServerRequestInterface
$mfaProvider : MfaProviderManifestInterface
Return values
ResponseInterface

addFlashMessage()

protected addFlashMessage(string $message[, string $title = '' ][, int $severity = FlashMessage::INFO ]) : void
Parameters
$message : string
$title : string = ''
$severity : int = FlashMessage::INFO

addFormButtons()

protected addFormButtons() : void

addOverviewButtons()

protected addOverviewButtons(ServerRequestInterface $request) : void
Parameters
$request : ServerRequestInterface

getActionUri()

Build a uri for the current controller based on the given action, respecting additional parameters.

protected getActionUri(string $action[, array<string|int, mixed> $additionalParameters = [] ]) : UriInterface
Parameters
$action : string
$additionalParameters : array<string|int, mixed> = []
Return values
UriInterface

getDefaultProviderIdentifier()

Get the default provider

protected getDefaultProviderIdentifier() : string
Return values
string

getRecommendedProviderIdentifier()

Get the recommended provider

protected getRecommendedProviderIdentifier() : string
Return values
string

getReturnUrl()

protected getReturnUrl(ServerRequestInterface $request) : string
Parameters
$request : ServerRequestInterface
Return values
string

hasSuitableDefaultProviders()

Check if there are more suitable default providers for the current user

protected hasSuitableDefaultProviders([array<string|int, mixed> $excludedProviders = [] ]) : bool
Parameters
$excludedProviders : array<string|int, mixed> = []
Return values
bool

initializeMfaConfiguration()

Initialize MFA configuration based on TSconfig and global configuration

protected initializeMfaConfiguration() : void

initializeView()

Initialize the standalone view and set the template name

protected initializeView(string $templateName) : StandaloneView
Parameters
$templateName : string
Return values
StandaloneView

isActionAllowed()

protected isActionAllowed(string $action) : bool
Parameters
$action : string
Return values
bool

isProviderAllowed()

protected isProviderAllowed(string $identifier) : bool
Parameters
$identifier : string
Return values
bool

isValidIdentifier()

protected isValidIdentifier(string $identifier) : bool
Parameters
$identifier : string
Return values
bool

removeDefaultProvider()

protected removeDefaultProvider() : void

        
On this page

Search results