Bitbucket fails to authenticate on git pull

后端 未结 16 1246
无人共我
无人共我 2020-12-12 11:40

I use BitBucket and had to change my password because it was compromised.

git pull

remote: Invalid username or password. If

相关标签:
16条回答
  • 2020-12-12 12:13

    This answer is for SO users who browse here after searching for the error.

    • Terminal will not accept your Bitbucket or Atlassian web app password if
      your account is associated with an Atlassian (Jira) account. If this is your case, you have a giant string generated for you that you can find in your MacOSX keychain app. This is the password Terminal accepts.
    • It is not clear how to re-generate this password or re-set it to match what Bitbucket will accept.
    • Changing password in SourceTree's settings did not work for me.
    • Changing password in Atlassian account profile did not work for me.
    • Bitbucket does not have a link or interface to change password for this case in the Bitbucket account profile - user has to go to Atlassian account profile.

    In my case, nothing worked because I changed my username in Bitbucket.

    Atlassian and Bitbucket are not completely integrated. Bitbucket uses the Atlassian user email and web app password, but allows you to have a different username.

    There seems to be a bug in this process, especially since it's not clear which application or process is generating the authentication and where it's stored or editable. Changing the username breaks authentication.

    There may be a way to update the username used by the credentials and Bitbucket, but I was already several hours behind when I discovered that changing my username back to what it was before restored authentication.

    0 讨论(0)
  • 2020-12-12 12:15

    I needed to do this and run a git pull in order to set my password from the command line in order to get this working.

    Note this method saves your password in a plain text file on your disk:

    git config --global credential.helper store
    git pull
    

    Other solutions here: Is there a way to skip password typing when using https:// on GitHub?

    0 讨论(0)
  • 2020-12-12 12:15

    Sometimes it happens when you change the remote bitbucket account password.

    Solution

    Go to Control panel => User Accounts => Credential Manager => Windows Credentials => move to Generic credentials and change the password of account
    
    0 讨论(0)
  • 2020-12-12 12:18

    If you found authentication error problem when you entered correct password and username it's git problem. To solves this problem when you are installing the git in your machine uncheck the enable git credential manager

    0 讨论(0)
  • 2020-12-12 12:21

    You can update your Bitbucket credentials from the OSX Keychain.

    Updating your cached credentials via the command line:

    $ git credential-osxkeychain erase
    host=bitbucket.org
    protocol=https
    [press return]
    

    If it's successful, nothing will print out. To test that it works, try and clone a repository from Bitbucket. If you are prompted for a password, the keychain entry was deleted.

    0 讨论(0)
  • 2020-12-12 12:22
    1. Firstly reset your password at "https://id.atlassian.com"
    2. Ensure you are able to login to Bitbucket Cloud - "https://bitbucket.org"
    3. Clear stored credentials on your machine a. Windows: Navigate to Credential Manager and clear stored credentials related to Bitbucket Cloud.
    4. Mac OS X: Navigate to Keychain Access and clear stored credentials related to Bitbucket
    5. Cloud Once this is done, try to login to perform a git operation authenticating to Bitbucket Cloud once again.
    0 讨论(0)
提交回复
热议问题