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

Support API token as credentials for git https (GitHub...)

XMLWordPrintable

    • Icon: Improvement Improvement
    • Resolution: Unresolved
    • Icon: Minor Minor
    • git-client-plugin
    • Docker Pipeline 1.14

      GitHub recommends for git+https to use API tokens instead of username & password.

      GitHub API token can be passed as a real token (https://<token>@github.com/username/bar.git) or as the username of a username:password auth (https://<token>:@github.com/username/bar.git).

      The client-client-plugin only supports username-password credentials for the moment (see o.j.p.gitclient.CliGitAPIImpl#getGitCredentialsURL()).

      Using a username-password-credentials storing the token in the username field is not a valid workaround as the GitHub API token is revealed in the GUI (see attached screenshot).

      Could we add support for Token as credentials for git+https and, if possible, introduce a credentials named "Token" as this name is more intuitive than "Secret Text".

            Unassigned Unassigned
            cleclerc Cyrille Le Clerc
            Votes:
            1 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: