Show / Hide Table of Contents

Class MfaSecondFactor

The different ways in which a user pool can obtain their MFA token for sign in.

Inheritance
object
MfaSecondFactor
Implements
IMfaSecondFactor
Inherited Members
object.GetType()
object.MemberwiseClone()
object.ToString()
object.Equals(object)
object.Equals(object, object)
object.ReferenceEquals(object, object)
object.GetHashCode()
Namespace: Amazon.CDK.AWS.Cognito
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public class MfaSecondFactor : IMfaSecondFactor
Syntax (vb)
Public Class MfaSecondFactor Implements IMfaSecondFactor
Remarks

See: https://docs.aws.amazon.com/cognito/latest/developerguide/user-pool-settings-mfa.html

ExampleMetadata: infused

Examples
new UserPool(this, "myuserpool", new UserPoolProps {
                 // ...
                 Mfa = Mfa.REQUIRED,
                 MfaSecondFactor = new MfaSecondFactor {
                     Sms = true,
                     Otp = true,
                     Email = false
                 }
             });

Synopsis

Constructors

MfaSecondFactor()

The different ways in which a user pool can obtain their MFA token for sign in.

Properties

Email

The MFA token is sent to the user via EMAIL.

Otp

The MFA token is a time-based one time password that is generated by a hardware or software token.

Sms

The MFA token is sent to the user via SMS to their verified phone numbers.

Constructors

MfaSecondFactor()

The different ways in which a user pool can obtain their MFA token for sign in.

public MfaSecondFactor()
Remarks

See: https://docs.aws.amazon.com/cognito/latest/developerguide/user-pool-settings-mfa.html

ExampleMetadata: infused

Examples
new UserPool(this, "myuserpool", new UserPoolProps {
                 // ...
                 Mfa = Mfa.REQUIRED,
                 MfaSecondFactor = new MfaSecondFactor {
                     Sms = true,
                     Otp = true,
                     Email = false
                 }
             });

Properties

Email

The MFA token is sent to the user via EMAIL.

public bool? Email { get; set; }
Property Value

bool?

Remarks

To enable email-based MFA, set email property to the Amazon SES email-sending configuration and set feturePlan to FeaturePlan.ESSENTIALS or FeaturePlan.PLUS

Default: false

See: https://docs.aws.amazon.com/cognito/latest/developerguide/user-pool-settings-mfa-sms-email-message.html

Otp

The MFA token is a time-based one time password that is generated by a hardware or software token.

public bool Otp { get; set; }
Property Value

bool

Remarks

Default: false

See: https://docs.aws.amazon.com/cognito/latest/developerguide/user-pool-settings-mfa-totp.html

Sms

The MFA token is sent to the user via SMS to their verified phone numbers.

public bool Sms { get; set; }
Property Value

bool

Remarks

Default: true

See: https://docs.aws.amazon.com/cognito/latest/developerguide/user-pool-settings-mfa-sms-email-message.html

Implements

IMfaSecondFactor
Back to top Generated by DocFX