function miniorange_2fa_inline_registration::mo_auth_inline_registration_page_four in Google Authenticator / 2 Factor Authentication - 2FA 8.2
Same name and namespace in other branches
- 8 src/Form/miniorange_2fa_inline_registration.php \Drupal\miniorange_2fa\form\miniorange_2fa_inline_registration::mo_auth_inline_registration_page_four()
1 call to miniorange_2fa_inline_registration::mo_auth_inline_registration_page_four()
- miniorange_2fa_inline_registration::buildForm in src/
Form/ miniorange_2fa_inline_registration.php - Form constructor.
File
- src/
Form/ miniorange_2fa_inline_registration.php, line 463 - Page 1: Select Email address. Page 2: Verify OTP. Page 3: Select Auth Method. Page 4: Configure Auth Method. Page 5: Configure KBA.
Class
- miniorange_2fa_inline_registration
- @file Page 1: Select Email address. Page 2: Verify OTP. Page 3: Select Auth Method. Page 4: Configure Auth Method. Page 5: Configure KBA.
Namespace
Drupal\miniorange_2fa\formCode
function mo_auth_inline_registration_page_four(array $form, FormStateInterface $form_state, $success_status, $message) {
$storage = $form_state
->getStorage();
$method = $storage['page_three_values']['mo_auth_method'];
if ($method == AuthenticationType::$GOOGLE_AUTHENTICATOR['code'] || $method == AuthenticationType::$MICROSOFT_AUTHENTICATOR['code'] || $method == AuthenticationType::$AUTHY_AUTHENTICATOR['code'] || $method == AuthenticationType::$LASTPASS_AUTHENTICATOR['code'] || $method == AuthenticationType::$DUO_AUTHENTICATOR['code']) {
return $this
->mo_auth_get_google_authentication_form($form, $form_state, $success_status);
}
elseif ($method == AuthenticationType::$KBA['code']) {
return $this
->mo_auth_get_kba_authentication_form($form, $form_state);
}
elseif ($method == AuthenticationType::$QR_CODE['code'] || $method == AuthenticationType::$PUSH_NOTIFICATIONS['code'] || $method == AuthenticationType::$SOFT_TOKEN['code']) {
return $this
->mo_auth_get_qrcode_authentication_form($form, $form_state, $success_status);
}
elseif ($method == AuthenticationType::$SMS['code'] || $method == AuthenticationType::$SMS_AND_EMAIL['code'] || $method == AuthenticationType::$EMAIL['code'] || $method == AuthenticationType::$OTP_OVER_PHONE['code']) {
return $this
->mo_auth_get_otp_over_sms_authentication_form($form, $form_state, $success_status, $message);
}
elseif ($method == AuthenticationType::$HARDWARE_TOKEN['code']) {
return $this
->mo_auth_get_hardware_token_validate_form($form, $form_state, $success_status, $message);
}
return null;
}