Class MFA

Multi-Factor Authentication

Hierarchy

  • MFA

Constructors

  • Construct MFA helper

    Parameters

    • client: Client

      Client

    • state: {
          email_mfa: boolean;
          email_otp: boolean;
          recovery_active: boolean;
          security_key_mfa: boolean;
          totp_mfa: boolean;
          trusted_handover: boolean;
      }

      State

      • email_mfa: boolean
      • email_otp: boolean
      • recovery_active: boolean
      • security_key_mfa: boolean
      • totp_mfa: boolean
      • trusted_handover: boolean

    Returns MFA

Properties

#client: Client
#store: [{
    email_mfa: boolean;
    email_otp: boolean;
    recovery_active: boolean;
    security_key_mfa: boolean;
    totp_mfa: boolean;
    trusted_handover: boolean;
}, SetStoreFunction<{
    email_mfa: boolean;
    email_otp: boolean;
    recovery_active: boolean;
    security_key_mfa: boolean;
    totp_mfa: boolean;
    trusted_handover: boolean;
}>]

Type declaration

  • email_mfa: boolean
  • email_otp: boolean
  • recovery_active: boolean
  • security_key_mfa: boolean
  • totp_mfa: boolean
  • trusted_handover: boolean

Accessors

  • get authenticatorEnabled(): boolean
  • Whether authenticator app is enabled

    Returns boolean

  • get availableMethods(): ("Password" | "Recovery" | "Totp")[]
  • Available MFA methods for generating tickets

    Returns ("Password" | "Recovery" | "Totp")[]

  • get recoveryEnabled(): boolean
  • Whether recovery codes are enabled

    Returns boolean

Methods

  • Create an MFA ticket

    Parameters

    • params: {
          password: string;
      } | {
          recovery_code: string;
      } | {
          totp_code: string;
      }

    Returns Promise<MFATicket>

    Token

  • Enable authenticator using token generated from secret found earlier

    Parameters

    • token: string

      Token

    Returns Promise<void>

Generated using TypeDoc