问题
Attempting to pull from my Stash project, using the following commands:
$ git remote add origin https://stash@stash.company.com/scm/~username/project.git
$ git pull origin develop
I'm prompted for my password, which I enter and then get the following error:
Your Stash account has been marked as requiring a CAPTCHA to be solved before you may login again. This is typically caused by too many attempts to login with an incorrect password. The required CAPTCHA prevents your SCM client from accessing Stash until it is solved, even if you enter your password correctly. If you are currently logged in to Stash via a browser you may need to logout and then log back in in order to clear the CAPTCHA.
Logging out and back in again does not help. How do I fix this?
回答1:
Another common issue with captcha warning seems to relate with password changes. Once your password is changed in the system you are authenticated with, both sourcetree and eclipse plug-in might have password conflict with the already logged in session on bitbucket, causing CAPTCHA authentication to activate.
Solution: Enter to your bitbucket session, logout and login again. If issue persist, then you might want to check the URL, since captcha activation would direct you to another direction and your user account with malfunctioning URL will raise authentication failures again and again.
回答2:
You might have a session to BitBucket open in a browser, that gives the impression that everything is fine. Simply logout and in again, when logging in you need to solve a CAPTCHA, after that you are good to go.
回答3:
In case of stash on macOS, this has worked for me:
- Close SourceTree
- Open Keychain Access
- Search for "stash", and remove any entries
- Go to stash website, log-out and login again
- Open SourceTree and enter your password
回答4:
This happened to me. I tried to remove sourcetree password file but didn't worked. I logout and login on bitbucket but didn't worked too. The thing that worked was to go to Panel Control on Windows and Credential Manager, I changed/removed all references to my git repo.
回答5:
What worked for me was to go into: C:\Users\UserName\AppData\Local\Atlassian\SourceTree and delete the passwd file. Sourcetree was closed and I was logged out of bitbucket. I then logged back into bitbucket and solved the captcha. Then when I launched sourcetree and did a fetch I entered my password and all was well.
回答6:
The problem was a malformed URL: it should be https://username@stash.company.com/scm/~username/project.git instead of stash@stash.
回答7:
For SourceTree when getting this error I had to do the following:
- In a browser Go to Stash/BitBucket and logout and login and validate using your new pwd and captcha. Once validated they would remove the captcha validation requirement on your account.
- If I come back to SourceTree and do a pull or fetch I still get the validation failed message since it tries to use same old stored password. In order to avoid using the old password try opening a Terminal from SourceTree itself and then do git fetch. It should ask for your new password and you can provide the new pwd which then gets stored.
回答8:
I was doing this log-out and log in again but it had no effect. I am on a corporate land with SSO (Single Sign-on) to log in to Stash. Then, I logged out and then did a hard refresh in my browser (Shift-refresh in FireFox). This brought up the login-screen with the captcha.
Once that was logged-in I went into SourceTree and deleted my password from Tools > Options > Authentication.
When I went back to do the pull request again it asked me in a pop-up for my password and worked well from there.
回答9:
In case you are using sourcetree, Go to Tools-->Options--> Authentication and delete Git saved passwords. This solved my issue
来源:https://stackoverflow.com/questions/30904285/stash-git-error-fatal-remote-error-captcha-required