Adds TOTP-2FA to SilverStripe
This module adds TOTP (Timed One-Time Password) 2FA support to SilverStripe.
- SilverStripe Framework 3.1
- OATH-OTP Implementation for PHP by rych
- Endroid QR Code
The easiest way to install this module is through composer. Simply add
"91carriage/2fa": "~1.0" to your project's
composer.json or run
require '91carriage/2fa:~1.0' from your projects main directory.
All configuration is done through the Configuration API. The currently available options are:
_91Carriage\Member.totp_window-- The number of tokens in the window users have to get a correct token. If this is 0, then only the current token is accepted. Note: this is the total size of the window, not the size either side of the current token. For example, the default value of 2 allows for users to specify the previous or the next tokens as well as the current one.
_91Carriage\BackupToken.single_use-- If backup tokens are single use. If set to true, if a backup token is used to login then it is deleted. Defaults to true.