forked from nfdi4plants/DataHUB
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Adding patch to deactivate (non OmniAuth) 2FA on DataHUB
- Loading branch information
dataplant
committed
May 16, 2024
1 parent
30b5451
commit f6c2693
Showing
1 changed file
with
35 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
--- /opt/gitlab/embedded/service/gitlab-rails/app/views/profiles/accounts/show.html.haml 2024-05-15 08:20:22.300932867 +0000 | ||
+++ /opt/gitlab/embedded/service/gitlab-rails/app/views/profiles/accounts/show.html.haml 2024-05-16 08:10:51.990471005 +0000 | ||
@@ -8,32 +8,6 @@ | ||
- c.with_body do | ||
= s_('Profiles|Some options are unavailable for LDAP accounts') | ||
|
||
-- if params[:two_factor_auth_enabled_successfully] | ||
- = render Pajamas::AlertComponent.new(variant: :success, | ||
- alert_options: { class: 'gl-my-5' }, | ||
- close_button_options: { class: 'js-close-2fa-enabled-success-alert' }) do |c| | ||
- - c.with_body do | ||
- = html_escape(_('You have set up 2FA for your account! If you lose access to your 2FA device, you can use your recovery codes to access your account. Alternatively, if you upload an SSH key, you can %{anchorOpen}use that key to generate additional recovery codes%{anchorClose}.')) % { anchorOpen: '<a href="%{href}">'.html_safe % { href: help_page_path('user/profile/account/two_factor_authentication', anchor: 'generate-new-recovery-codes-using-ssh') }, anchorClose: '</a>'.html_safe } | ||
- | ||
-.settings-section.js-search-settings-section | ||
- .settings-sticky-header | ||
- .settings-sticky-header-inner | ||
- %h4.gl-my-0 | ||
- = s_('Profiles|Two-factor authentication') | ||
- %p.gl-text-secondary | ||
- = s_("Profiles|Increase your account's security by enabling two-factor authentication (2FA).") | ||
- %div | ||
- %p | ||
- %span.gl-font-weight-bold | ||
- #{_('Status')}: | ||
- #{current_user.two_factor_enabled? ? _('Enabled') : _('Disabled')} | ||
- - if current_user.two_factor_enabled? | ||
- = render Pajamas::ButtonComponent.new(variant: :confirm, href: profile_two_factor_auth_path) do | ||
- = _('Manage two-factor authentication') | ||
- - else | ||
- = render Pajamas::ButtonComponent.new(variant: :confirm, href: profile_two_factor_auth_path, button_options: { data: { testid: 'enable-2fa-button' }}) do | ||
- = _('Enable two-factor authentication') | ||
- | ||
- if display_providers_on_profile? | ||
.settings-section.js-search-settings-section | ||
.settings-sticky-header |