PHP Interface AppserverIo\Appserver\ServletEngine\Security\RealmInterface

Show file Open project: appserver-io/appserver Interface Usage Examples

Public Methods

Method Description
authenticate ( string $username, string $password ) : AppserverIo\Security\PrincipalInterface | null Tries to authenticate the user with the passed username and password.
authenticateByUsernameAndCallbackHandler ( string $username, AppserverIo\Psr\Security\Auth\Callback\CallbackHandlerInterface $callbackHandler ) : AppserverIo\Security\PrincipalInterface | null Tries to authenticate the user with the passed username and callback handler.
getConfiguration ( ) : AppserverIo\Appserver\Core\Api\Node\SecurityDomainNodeInterface Return's the realm's configuration.
getExceptionStack ( ) : AppserverIo\Collections\ArrayList Return's the exception stack.
getName ( ) : string Return's the name of the realm.

Method Details

authenticate() public method

Tries to authenticate the user with the passed username and password.
public authenticate ( string $username, string $password ) : AppserverIo\Security\PrincipalInterface | null
$username string The name of the user to authenticate
$password string The password used for authentication
return AppserverIo\Security\PrincipalInterface | null The authenticated user principal

authenticateByUsernameAndCallbackHandler() public method

Tries to authenticate the user with the passed username and callback handler.
public authenticateByUsernameAndCallbackHandler ( string $username, AppserverIo\Psr\Security\Auth\Callback\CallbackHandlerInterface $callbackHandler ) : AppserverIo\Security\PrincipalInterface | null
$username string The name of the user to authenticate
$callbackHandler AppserverIo\Psr\Security\Auth\Callback\CallbackHandlerInterface The callback handler used to load the credentials
return AppserverIo\Security\PrincipalInterface | null The authenticated user principal

getConfiguration() public method

Return's the realm's configuration.
public getConfiguration ( ) : AppserverIo\Appserver\Core\Api\Node\SecurityDomainNodeInterface
return AppserverIo\Appserver\Core\Api\Node\SecurityDomainNodeInterface The realm's configuration

getExceptionStack() public method

Return's the exception stack.
public getExceptionStack ( ) : AppserverIo\Collections\ArrayList
return AppserverIo\Collections\ArrayList The exception stack

getName() public method

Return's the name of the realm.
public getName ( ) : string
return string The realm's name