ElliotSawyer\TOTPAuthenticator\TOTPAuthenticator
Class TOTPAuthenticator
Synopsis
class TOTPAuthenticator
extends BootstrapMFAAuthenticator
{
- // members
- private static string $algorithm = 'sha1';
- // methods
- public LoginHandler|static getLoginHandler()
- public bool|null|Member validateTOTP()
- protected bool|int|string getTokenFromTOTP()
- public static string get_algorithm()
Hierarchy
Extends
- Firesphere\BootstrapMFA\Authenticators\BootstrapMFAAuthenticator
Uses
- SilverStripe\Core\Config\Configurable
Members
private
-
$algorithm
Google Authenticator and Authy only support tokens generated with SHA-1 Other authenticators MAY implement SHA-256 or SHA-512 as outlined in RFC6238 You may use the Config API to adjust this algorithm if you need to support a specific TOTP authenticator
Methods
protected
- getTokenFromTOTP() — Given a TOTP secret, use Totp to resolve to a one time token
public
- getLoginHandler()
- get_algorithm() — Get configured algorithm for TOTP Authenticator
- validateTOTP()