Reset Jenkins password if username was left blank
So we not only reset password if URL was changed, but also for username. Also, still require username if a new password was set.
Merge request reports
Activity
Added 1 commit:
- 6d0731e4 - Test resetting password and validating username
Added 3 commits:
-
6d0731e4...6d7a6424 - 2 commits from branch
master
- 7bcfe097 - Merge remote-tracking branch 'upstream/master' into reset-jenkins-password-when-username-is-blank
-
6d0731e4...6d7a6424 - 2 commits from branch
Reassigned to @grzesiek
Reassigned to @ayufan
Could you look if this is what we want to solve?
@balameb Yes, as long as you remove the username, then password is not required. If you set password, then username is required.
password.present?
check the existence of password, howeverpassword_touched?
check if the password is entered or not. The real line to remove password is https://gitlab.com/gitlab-org/gitlab-ee/merge_requests/775/diffs#20a22acf641a263495eaba829c6d2ca143d8a1f6_38_37 which would remove the password whenever username is given blank. Note that this happens after validation so it won't triggerpassword_touched?
which is used in validation.@balameb Please confirm and let's merge it?
Mentioned in commit e6ec9645