feat: add managing mfa
This commit is contained in:
@@ -107,6 +107,12 @@ func MetaResolver(ctx context.Context) (*model.Meta, error) {
|
||||
isSignUpDisabled = true
|
||||
}
|
||||
|
||||
isMultiFactorAuthenticationEnabled, err := memorystore.Provider.GetBoolStoreEnvVariable(constants.EnvKeyDisableMultiFactorAuthentication)
|
||||
if err != nil {
|
||||
log.Debug("Failed to get Disable Multi Factor Authentication from environment variable", err)
|
||||
isSignUpDisabled = true
|
||||
}
|
||||
|
||||
metaInfo := model.Meta{
|
||||
Version: constants.VERSION,
|
||||
ClientID: clientID,
|
||||
@@ -120,6 +126,7 @@ func MetaResolver(ctx context.Context) (*model.Meta, error) {
|
||||
IsMagicLinkLoginEnabled: !isMagicLinkLoginDisabled,
|
||||
IsSignUpEnabled: !isSignUpDisabled,
|
||||
IsStrongPasswordEnabled: !isStrongPasswordDisabled,
|
||||
IsMultiFactorAuthEnabled: !isMultiFactorAuthenticationEnabled,
|
||||
}
|
||||
return &metaInfo, nil
|
||||
}
|
||||
|
Reference in New Issue
Block a user