PHP Интерфейс Neos\Flow\Security\Authentication\TokenInterface

Показать файл Открыть проект Примеры использования интерфейса

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

Метод Описание
__toString ( ) : string Returns a string representation of the token for logging purposes.
getAccount ( ) : Account Returns the account if one is authenticated, NULL otherwise.
getAuthenticationEntryPoint ( ) : Neos\Flow\Security\Authentication\EntryPointInterface Returns the configured authentication entry point, NULL if none is available
getAuthenticationProviderName ( ) : string Returns the name of the authentication provider responsible for this token
getAuthenticationStatus ( ) : integer Returns the current authentication status
getCredentials ( ) : mixed Returns the credentials of this token. The type depends on the provider of the token.
getRequestPatterns ( ) : array Returns an array of set \Neos\Flow\Security\RequestPatternInterface, NULL if none was set
hasRequestPatterns ( ) : boolean Returns TRUE if \Neos\Flow\Security\RequestPattern were set
isAuthenticated ( ) : boolean Returns TRUE if this token is currently authenticated
setAccount ( Account $account = null ) : void Set the (authenticated) account
setAuthenticationEntryPoint ( Neos\Flow\Security\Authentication\EntryPointInterface $entryPoint ) : void Sets the authentication entry point
setAuthenticationProviderName ( string $authenticationProviderName ) : void Sets the name of the authentication provider responsible for this token
setAuthenticationStatus ( integer $authenticationStatus ) : void Sets the authentication status. Usually called by the responsible AuthenticationManagerInterface
setRequestPatterns ( array $requestPatterns ) : void Sets request patterns
updateCredentials ( ActionRequest $actionRequest ) : boolean Updates the authentication credentials, the authentication manager needs to authenticate this token.

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

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

Returns a string representation of the token for logging purposes.
public __toString ( ) : string
Результат string A string representation of the token

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

Returns the account if one is authenticated, NULL otherwise.
public getAccount ( ) : Account
Результат Neos\Flow\Security\Account An account object

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

Returns the configured authentication entry point, NULL if none is available
public getAuthenticationEntryPoint ( ) : Neos\Flow\Security\Authentication\EntryPointInterface
Результат Neos\Flow\Security\Authentication\EntryPointInterface The configured authentication entry point, NULL if none is available

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

Returns the name of the authentication provider responsible for this token
public getAuthenticationProviderName ( ) : string
Результат string The authentication provider name

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

Returns the current authentication status
public getAuthenticationStatus ( ) : integer
Результат integer One of NO_CREDENTIALS_GIVEN, WRONG_CREDENTIALS, AUTHENTICATION_SUCCESSFUL, REAUTHENTICATION_NEEDED

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

Returns the credentials of this token. The type depends on the provider of the token.
public getCredentials ( ) : mixed
Результат mixed $credentials The needed credentials to authenticate this token

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

Returns an array of set \Neos\Flow\Security\RequestPatternInterface, NULL if none was set
См. также: hasRequestPattern()
public getRequestPatterns ( ) : array
Результат array Array of set request patterns

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

Returns TRUE if \Neos\Flow\Security\RequestPattern were set
public hasRequestPatterns ( ) : boolean
Результат boolean True if a \Neos\Flow\Security\RequestPatternInterface was set

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

Returns TRUE if this token is currently authenticated
public isAuthenticated ( ) : boolean
Результат boolean TRUE if this this token is currently authenticated

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

Set the (authenticated) account
public setAccount ( Account $account = null ) : void
$account Neos\Flow\Security\Account An account object
Результат void

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

Sets the authentication entry point
public setAuthenticationEntryPoint ( Neos\Flow\Security\Authentication\EntryPointInterface $entryPoint ) : void
$entryPoint Neos\Flow\Security\Authentication\EntryPointInterface The authentication entry point
Результат void

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

Sets the name of the authentication provider responsible for this token
public setAuthenticationProviderName ( string $authenticationProviderName ) : void
$authenticationProviderName string The authentication provider name
Результат void

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

Sets the authentication status. Usually called by the responsible AuthenticationManagerInterface
public setAuthenticationStatus ( integer $authenticationStatus ) : void
$authenticationStatus integer One of NO_CREDENTIALS_GIVEN, WRONG_CREDENTIALS, AUTHENTICATION_SUCCESSFUL
Результат void

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

Sets request patterns
См. также: hasRequestPattern()
public setRequestPatterns ( array $requestPatterns ) : void
$requestPatterns array Array of \Neos\Flow\Security\RequestPatternInterface to be set
Результат void

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

This could be a username/password from a login controller. This method is called while initializing the security context. By returning TRUE you make sure that the authentication manager will (re-)authenticate the tokens with the current credentials. Note: You should not persist the credentials!
public updateCredentials ( ActionRequest $actionRequest ) : boolean
$actionRequest Neos\Flow\Mvc\ActionRequest The current request instance
Результат boolean TRUE if this token needs to be (re-)authenticated