_2fa\Extensions\TwoFactorAuthMemberExtension
Synopsis
class TwoFactorAuthMemberExtension
extends DataExtension
{
- // members
- private static array $db = ;
- private static array $has_many = ;
- private static boolean $admins_can_disable = false;
- private static boolean $validated_activation_mode = false;
- private static integer $totp_window = 2;
- // methods
- public static void validated_activation_mode()
- public void validateTOTP()
- public void getPrintableTOTPToken()
- public void OTPSeed()
- public void updateCMSFields()
- public void updateFieldLabels()
- public void generateTOTPToken()
- public void onBeforeDelete()
- public void onBeforeWrite()
- public void getOTPUrl()
- public void generateQRCode()
Hierarchy
Extends
- DataExtension
Members
private
- $admins_can_disable
- $db
- $has_many
- $totp_window
- $validated_activation_mode
Methods
public
- OTPSeed()
- generateQRCode()
- generateTOTPToken()
- getOTPUrl()
- getPrintableTOTPToken()
- onBeforeDelete() — Delete a member's backup tokens when deleting the member.
- onBeforeWrite()
- updateCMSFields() — Allow other admins to turn off 2FA if it is set & admins_can_disable is set in the config.
- updateFieldLabels()
- validateTOTP()
- validated_activation_mode()