Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-17332

User-name "is already taken" but not shown in user list

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • _unsorted
    • None

      System tried to send mail to user grixon@ast.cam.ac.uk where grixon is an account that has committed changes to SVN and ast.cam.ac.uk is the default email domain. I went to change that user's email setting and found the account not listed in the "manage users" page. I then tried to create the account and was told "account is already taken".

          [JENKINS-17332] User-name "is already taken" but not shown in user list

          Kanstantsin Shautsou added a comment - - edited

          This thing is very odd.
          If you configured jenkins with:
          "Security realm" -> "own database" + "allow sign up"
          Then after runing some build that creates SCM people, you can't "sign up" with existed SCM username.
          Probably during sign up jenkins should check user database instead of SCM people.
          https://github.com/jenkinsci/jenkins/blob/master/core/src/main/java/hudson/security/HudsonPrivateSecurityRealm.java#L311

          This problem can be bypassed by setting password in /user/USERNAME/configure manually by administrator. It will automatically create real internal user /securityRealm/

          Kanstantsin Shautsou added a comment - - edited This thing is very odd. If you configured jenkins with: "Security realm" -> "own database" + "allow sign up" Then after runing some build that creates SCM people, you can't "sign up" with existed SCM username. Probably during sign up jenkins should check user database instead of SCM people. https://github.com/jenkinsci/jenkins/blob/master/core/src/main/java/hudson/security/HudsonPrivateSecurityRealm.java#L311 This problem can be bypassed by setting password in /user/USERNAME/configure manually by administrator. It will automatically create real internal user /securityRealm/

          The real user has two additional properties:

          hudson.security.HudsonPrivateSecurityRealm$Details@13b6fe6b, 
          org.jenkinsci.main.modules.cli.auth.ssh.UserPropertyImpl@52f92ce9, 
          

          First looks more suitable for check.

          Kanstantsin Shautsou added a comment - The real user has two additional properties: hudson.security.HudsonPrivateSecurityRealm$Details@13b6fe6b, org.jenkinsci.main.modules.cli.auth.ssh.UserPropertyImpl@52f92ce9, First looks more suitable for check.

          Well, this problem was introduced from 255a3e6dd67d91e74541293bf7d3ea696b01b6c1 JENKINS-7096

          Kanstantsin Shautsou added a comment - Well, this problem was introduced from 255a3e6dd67d91e74541293bf7d3ea696b01b6c1 JENKINS-7096

          Kanstantsin Shautsou added a comment - https://github.com/jenkinsci/jenkins/pull/902

          Fix moved to separate PR #908 https://github.com/jenkinsci/jenkins/pull/908

          Kanstantsin Shautsou added a comment - Fix moved to separate PR #908 https://github.com/jenkinsci/jenkins/pull/908

          reassigned to reviewer

          Kanstantsin Shautsou added a comment - reassigned to reviewer

          Code changed in jenkins
          User: Kanstantsin Shautsou
          Path:
          core/src/main/java/hudson/security/HudsonPrivateSecurityRealm.java
          http://jenkins-ci.org/commit/jenkins/f633a44ffba7c4a3b78aaecdb07aebdafa3814dd
          Log:
          JENKINS-17332 Allow sign up with username that exist because of SCM people.

          SCM/JIRA link daemon added a comment - Code changed in jenkins User: Kanstantsin Shautsou Path: core/src/main/java/hudson/security/HudsonPrivateSecurityRealm.java http://jenkins-ci.org/commit/jenkins/f633a44ffba7c4a3b78aaecdb07aebdafa3814dd Log: JENKINS-17332 Allow sign up with username that exist because of SCM people.

          Code changed in jenkins
          User: Michael Clarke
          Path:
          core/src/main/java/hudson/security/HudsonPrivateSecurityRealm.java
          http://jenkins-ci.org/commit/jenkins/b52e32eda3186814e90e0d42407ad164dc1b3d08
          Log:
          Merge pull request #908 from KostyaSha/JENKINS-17332

          JENKINS-17332 Allow sign up with username that exists because of SCM commit.

          Compare: https://github.com/jenkinsci/jenkins/compare/4d8bfb55388c...b52e32eda318

          SCM/JIRA link daemon added a comment - Code changed in jenkins User: Michael Clarke Path: core/src/main/java/hudson/security/HudsonPrivateSecurityRealm.java http://jenkins-ci.org/commit/jenkins/b52e32eda3186814e90e0d42407ad164dc1b3d08 Log: Merge pull request #908 from KostyaSha/ JENKINS-17332 JENKINS-17332 Allow sign up with username that exists because of SCM commit. Compare: https://github.com/jenkinsci/jenkins/compare/4d8bfb55388c...b52e32eda318

          dogfood added a comment -

          Integrated in jenkins_main_trunk #2810
          JENKINS-17332 Allow sign up with username that exist because of SCM people. (Revision f633a44ffba7c4a3b78aaecdb07aebdafa3814dd)

          Result = SUCCESS
          Kanstantsin_Shautsou : f633a44ffba7c4a3b78aaecdb07aebdafa3814dd
          Files :

          • core/src/main/java/hudson/security/HudsonPrivateSecurityRealm.java

          dogfood added a comment - Integrated in jenkins_main_trunk #2810 JENKINS-17332 Allow sign up with username that exist because of SCM people. (Revision f633a44ffba7c4a3b78aaecdb07aebdafa3814dd) Result = SUCCESS Kanstantsin_Shautsou : f633a44ffba7c4a3b78aaecdb07aebdafa3814dd Files : core/src/main/java/hudson/security/HudsonPrivateSecurityRealm.java

          Fixed, closing.

          Kanstantsin Shautsou added a comment - Fixed, closing.

            mc1arke Michael Clarke
            guyrixon Guy Rixon
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved: