TwoFactorAuthWriteService
in package
Class representing a two-factor-authorization write service
Table of Contents
- $configurationStorage : AuthConfigurationStorage
- Configuration storage
- $safetyFileStorage : AuthSafetyFileStorage
- Safety file storage
- __construct() : mixed
- Create instance
- safetyFileForCustomer() : $this
- Create a safety file for the provided customer ID
- secretForCustomer() : $this
- Store a secret for the provided customer ID
Properties
$configurationStorage
Configuration storage
protected
AuthConfigurationStorage
$configurationStorage
$safetyFileStorage
Safety file storage
protected
AuthSafetyFileStorage
$safetyFileStorage
Methods
__construct()
Create instance
public
__construct(AuthConfigurationStorage $configurationStorage, AuthSafetyFileStorage $safetyFileStorage) : mixed
Parameters
- $configurationStorage : AuthConfigurationStorage
-
Configuration storage
- $safetyFileStorage : AuthSafetyFileStorage
-
Safety file storage
Return values
mixed —safetyFileForCustomer()
Create a safety file for the provided customer ID
public
safetyFileForCustomer(IdType $customerId) : $this
Parameters
- $customerId : IdType
-
Customer ID
Return values
$this —Same instance
secretForCustomer()
Store a secret for the provided customer ID
public
secretForCustomer(IdType $customerId[, AuthSecret|null $providedSecret = null ]) : $this
Parameters
- $customerId : IdType
-
Customer ID
- $providedSecret : AuthSecret|null = null
-
If omitted, a random secret is used
Return values
$this —Same instance