PHP Класс Neos\Flow\Security\Authentication\AuthenticationProviderManager

Наследование: implements Neos\Flow\Security\Authentication\AuthenticationManagerInterface
Показать файл Открыть проект Примеры использования класса

Защищенные свойства (Protected)

Свойство Тип Описание
$isAuthenticated boolean
$providerResolver AuthenticationProviderResolver The provider resolver
$providers array
$requestPatternResolver Neos\Flow\Security\RequestPatternResolver The request pattern resolver
$securityContext Neos\Flow\Security\Context The security context of the current request
$securityLogger Neos\Flow\Log\SecurityLoggerInterface
$session Neos\Flow\Session\SessionInterface
$tokens array

Открытые методы

Метод Описание
__construct ( AuthenticationProviderResolver $providerResolver, RequestPatternResolver $requestPatternResolver )
authenticate ( ) : void Tries to authenticate the tokens in the security context (in the given order) with the available authentication providers, if needed.
getProviders ( ) : array Returns all configured authentication providers
getSecurityContext ( ) : Context Returns the security context
getTokens ( ) : array Returns clean tokens this manager is responsible for.
injectSettings ( array $settings ) : void Inject the settings and does a fresh build of tokens based on the injected settings
isAuthenticated ( ) : boolean Checks if one or all tokens are authenticated (depending on the authentication strategy).
logout ( ) : void Logout all active authentication tokens
setSecurityContext ( Context $securityContext ) : void Sets the security context

Защищенные методы

Метод Описание
buildProvidersAndTokensFromConfiguration ( array $providerConfigurations ) : void Builds the provider and token objects based on the given configuration
emitAuthenticatedToken ( Neos\Flow\Security\Authentication\TokenInterface $token ) : void Signals that the specified token has been successfully authenticated.
emitLoggedOut ( ) : void Signals that all active authentication tokens have been invalidated.

Описание методов

__construct() публичный Метод

public __construct ( AuthenticationProviderResolver $providerResolver, RequestPatternResolver $requestPatternResolver )
$providerResolver AuthenticationProviderResolver The provider resolver
$requestPatternResolver Neos\Flow\Security\RequestPatternResolver The request pattern resolver

authenticate() публичный Метод

If the authentication strategy is set to "allTokens", all tokens have to be authenticated. If the strategy is set to "oneToken", only one token needs to be authenticated, but the authentication will stop after the first authenticated token. The strategy "atLeastOne" will try to authenticate at least one and as many tokens as possible.
public authenticate ( ) : void
Результат void

buildProvidersAndTokensFromConfiguration() защищенный Метод

Builds the provider and token objects based on the given configuration
protected buildProvidersAndTokensFromConfiguration ( array $providerConfigurations ) : void
$providerConfigurations array The configured provider settings
Результат void

emitAuthenticatedToken() защищенный Метод

Signals that the specified token has been successfully authenticated.
protected emitAuthenticatedToken ( Neos\Flow\Security\Authentication\TokenInterface $token ) : void
$token Neos\Flow\Security\Authentication\TokenInterface The token which has been authenticated
Результат void

emitLoggedOut() защищенный Метод

Note: the session will be destroyed after this signal has been emitted.
protected emitLoggedOut ( ) : void
Результат void

getProviders() публичный Метод

Returns all configured authentication providers
public getProviders ( ) : array
Результат array Array of \Neos\Flow\Security\Authentication\AuthenticationProviderInterface

getSecurityContext() публичный Метод

Returns the security context
public getSecurityContext ( ) : Context
Результат Neos\Flow\Security\Context $securityContext The security context of the current request

getTokens() публичный Метод

Note: The order of the tokens in the array is important, as the tokens will be authenticated in the given order.
public getTokens ( ) : array
Результат array Array of TokenInterface this manager is responsible for

injectSettings() публичный Метод

Inject the settings and does a fresh build of tokens based on the injected settings
public injectSettings ( array $settings ) : void
$settings array The settings
Результат void

isAuthenticated() публичный Метод

Will call authenticate() if not done before.
public isAuthenticated ( ) : boolean
Результат boolean

logout() публичный Метод

Logout all active authentication tokens
public logout ( ) : void
Результат void

setSecurityContext() публичный Метод

Sets the security context
public setSecurityContext ( Context $securityContext ) : void
$securityContext Neos\Flow\Security\Context The security context of the current request
Результат void

Описание свойств

$isAuthenticated защищенное свойство

protected bool $isAuthenticated
Результат boolean

$providerResolver защищенное свойство

The provider resolver
protected AuthenticationProviderResolver,Neos\Flow\Security\Authentication $providerResolver
Результат AuthenticationProviderResolver

$providers защищенное свойство

protected array $providers
Результат array

$requestPatternResolver защищенное свойство

The request pattern resolver
protected RequestPatternResolver,Neos\Flow\Security $requestPatternResolver
Результат Neos\Flow\Security\RequestPatternResolver

$securityContext защищенное свойство

The security context of the current request
protected Context,Neos\Flow\Security $securityContext
Результат Neos\Flow\Security\Context

$securityLogger защищенное свойство

protected SecurityLoggerInterface,Neos\Flow\Log $securityLogger
Результат Neos\Flow\Log\SecurityLoggerInterface

$session защищенное свойство

protected SessionInterface,Neos\Flow\Session $session
Результат Neos\Flow\Session\SessionInterface

$tokens защищенное свойство

protected array $tokens
Результат array