Send user back to referer page after successful identity verification
What does this MR do and why?
Implements https://gitlab.com/gitlab-org/modelops/anti-abuse/team-tasks/-/issues/634.
Redirect the user back to where they came from after they complete identity verification.
What is not in this MR
The actual alerts that will redirect the user to the Identity Verification page. These will be implemented as part of https://gitlab.com/gitlab-org/modelops/anti-abuse/team-tasks/-/issues/651.
MR acceptance checklist
Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.
Screenshots or screen recordings
Screen_Recording_2024-04-24_at_3.31.48_PM
How to set up and validate locally
-
Start GDK simulating SaaS
export GITLAB_SIMULATE_SAAS=1 && gdk start
-
Enable
opt_in_identity_verification
FF$ rails c > Feature.enable(:opt_in_identity_verification)
-
Setup Telesign
$ rails c > ApplicationSetting.first.update(telesign_customer_xid: '<value_is_in_1Pass>', telesign_api_key: '<value_is_in_1Pass>')
Credentials are in 1Password under Telesign API Keys (use
GITLAB - DEVELOPMENT
) -
Update create new group page to show an alert that redirects to Identity Verification page
diff --git a/app/assets/javascripts/vue_shared/new_namespace/new_namespace_page.vue b/app/assets/javascripts/vue_shared/new_namespace/new_namespace_page.vue index 52327617d2622..a170cb3f19eb5 100644 --- a/app/assets/javascripts/vue_shared/new_namespace/new_namespace_page.vue +++ b/app/assets/javascripts/vue_shared/new_namespace/new_namespace_page.vue @@ -1,5 +1,5 @@ <script> -import { GlBreadcrumb, GlIcon } from '@gitlab/ui'; +import { GlAlert, GlBreadcrumb, GlIcon } from '@gitlab/ui'; import NewTopLevelGroupAlert from '~/groups/components/new_top_level_group_alert.vue'; import SuperSidebarToggle from '~/super_sidebar/components/super_sidebar_toggle.vue'; @@ -16,6 +16,7 @@ export default { WelcomePage, LegacyContainer, SuperSidebarToggle, + GlAlert, }, props: { title: { @@ -150,6 +151,7 @@ export default { <slot name="extra-description"></slot> </div> + <div> <new-top-level-group-alert v-if="showNewTopLevelGroupAlert" /> <legacy-container :key="activePanel.name" :selector="activePanel.selector" /> @@ -158,6 +160,16 @@ export default { <welcome-page v-else :panels="panels" :title="title"> <template #footer> + <gl-alert + :title="'Test'" + :dismissible="false" + :primary-button-text="'Go to Identity Verification page'" + :primary-button-link="'/-/identity_verification'" + variant="danger" + > + {{ 'Test' }} + </gl-alert> + <slot name="welcome-footer"></slot> </template> </welcome-page>
-
Login with
root
user -
Go through phone number verification
-
After verifying the sent code, click on
Next
-
Verify that you are redirected back to http://localhost:3000/groups/new