PHP Class Scheb\TwoFactorBundle\Security\TwoFactor\Trusted\TrustedComputerManager

Inheritance: implements Scheb\TwoFactorBundle\Security\TwoFactor\Trusted\TrustedComputerManagerInterface
Show file Open project: scheb/two-factor-bundle Class Usage Examples

Public Methods

Method Description
__construct ( Scheb\TwoFactorBundle\Model\PersisterInterface $persister )
addTrustedComputer ( mixed $user, string $token, DateTime $validUntil ) Add a trusted computer token for a user.
isTrustedComputer ( mixed $user, string $token ) : boolean Validate a trusted computer token for a user.

Method Details

__construct() public method

public __construct ( Scheb\TwoFactorBundle\Model\PersisterInterface $persister )
$persister Scheb\TwoFactorBundle\Model\PersisterInterface

addTrustedComputer() public method

Add a trusted computer token for a user.
public addTrustedComputer ( mixed $user, string $token, DateTime $validUntil )
$user mixed
$token string
$validUntil DateTime

isTrustedComputer() public method

Validate a trusted computer token for a user.
public isTrustedComputer ( mixed $user, string $token ) : boolean
$user mixed
$token string
return boolean