Commit 3e32dce8 authored by Douwe Maan's avatar Douwe Maan
Browse files

Merge branch 'fj-28141-redirection-loop' into 'master'

Removing the two factor check when the user sets a new password

Closes #28141

See merge request gitlab-org/gitlab-ce!17457
class Profiles::PasswordsController < Profiles::ApplicationController
skip_before_action :check_password_expiration, only: [:new, :create]
skip_before_action :check_two_factor_requirement, only: [:new, :create]
before_action :set_user
before_action :authorize_change_password!
......
---
title: Removing the two factor check when the user sets a new password
merge_request: 17457
author:
type: fixed
......@@ -134,5 +134,15 @@ def fill_passwords(password, confirmation)
expect(current_path).to eq new_user_session_path
end
context 'when global require_two_factor_authentication is enabled' do
it 'needs change user password' do
stub_application_setting(require_two_factor_authentication: true)
visit profile_path
expect(current_path).to eq new_profile_password_path
end
end
end
end
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment