Bitbucket Cloud recently stopped supporting account passwords for Git authentication
Asked Answered
G

6

29

I have pushed the code in the morning it was working fine but now I'm trying to push code but getting this error: Bitbucket Cloud recently stopped supporting account passwords for Git authentication

Gillies answered 14/3, 2022 at 17:39 Comment(2)
Instead of using your own Atlassian account password you should use an app password. This can be done on this page. Read more about the deprecation notice here.Silda
See also How to access bitbucket using app passwordMastectomy
M
27

You can also make the update in Sourcetree pretty easily, but you still need to create an app password first.

Create App Password:

  1. Navigate to: https://bitbucket.org/account/settings/app-passwords/
  2. Create an App Password with the required permissions

The password will only show once, so make sure to copy it as you will need it later.

Update in Sourcetree:

  1. Click the settings button on the top right corner of the repository tab
  2. In Repository Settings -> Remotes: double click the Path for origin.
  3. In Remote Details -> Required Information: edit the URL/Path by adding the app password that was created with your account, the format must be as shown below:

https://{{BitbucketUsername}}:{{AppPassword}}@bitbucket.org/{{RepoName}}.git

Maudmaude answered 5/4, 2022 at 16:44 Comment(1)
This is highly insecure, as it hardwires the credentials into the URL (!). However, thanks a lot, as this was the only way I could push requests again with SourceTree and MacOS. Congratulations to SourceTree and ATLASSIAN for returning me to the 20th century again!Martel
L
50

I've also faced this issue..

  1. Then I opened my Bitbucket account.

  2. Then at the bottom left corner you will find an icon with your username's initials.

  3. Click on that and go to settings and click on Personal Settings

  4. In personal Settings, in the left panel you will find "access management"

  5. Under that you will find "app passwords"

  6. Click on that --> Then you will routed to create app password page

  7. There you can give the required permissions and create password (Note: You have to store that password somewhere as it will be displayed only once)

  8. When you push the code to any repo...use your app password instead of your account password (No need to change any settings in the git_config file)

Happy programming :) !

Loincloth answered 15/3, 2022 at 5:6 Comment(0)
M
27

You can also make the update in Sourcetree pretty easily, but you still need to create an app password first.

Create App Password:

  1. Navigate to: https://bitbucket.org/account/settings/app-passwords/
  2. Create an App Password with the required permissions

The password will only show once, so make sure to copy it as you will need it later.

Update in Sourcetree:

  1. Click the settings button on the top right corner of the repository tab
  2. In Repository Settings -> Remotes: double click the Path for origin.
  3. In Remote Details -> Required Information: edit the URL/Path by adding the app password that was created with your account, the format must be as shown below:

https://{{BitbucketUsername}}:{{AppPassword}}@bitbucket.org/{{RepoName}}.git

Maudmaude answered 5/4, 2022 at 16:44 Comment(1)
This is highly insecure, as it hardwires the credentials into the URL (!). However, thanks a lot, as this was the only way I could push requests again with SourceTree and MacOS. Congratulations to SourceTree and ATLASSIAN for returning me to the 20th century again!Martel
Q
8

After creating the app password from bitbucket cloud, I reset remote url like the following.

git remote set-url origin https://<Bitbucket_Username>:<App_Password>@bitbucket.org/<Repo_Name>.git

After resetting the remote url, I couldn't manage to pull push or any other git operation. Got an error message, like remote repository doesn't exits.

To solve this issue, I reset back to the url which was before this. Then run some git command and when the sign in window appears, I put the app password instead of the bitbucket account password and it worked for me.

Quibbling answered 15/3, 2022 at 15:34 Comment(2)
when i did the same, it giving me no such remote origin.Havard
This is exactly how it worked for me too. Thanks for the topTrioxide
C
2

On Windows after creating password I had do as below to fix my issue:

If this does not work you can try one more thing before reinstalling Sourcetree for Windows.

Navigate to C:\Users<UserName>\AppData\Local\Atlassian\Sourcetree and remove the passwd file. Please be warned, that after removing this file, Sourcetree for Windows may eventually prompt you for your password(s) again. Next, again try and push and/or pull some code to your Bitbucket Cloud repository. If it works then you can ignore the following steps.

Cnemis answered 9/4, 2022 at 1:25 Comment(0)
I
1

The guidance suppose to be like this:

  1. Go to the bitbucket.org website and log in with your account credentials.
  2. Click avatar and it will show the submenu, then click Personal Settings.
  3. Click App passwords under ACCESS MANAGEMENT.
  4. Click Create App password.
  5. You will fill out the Label and pick the Permissions.
  6. The password will be generated automatically by showing the modal and you need to remember or save the password because it'll be used to set the git credentials.

After that, back to your console and type below

git remote set-url origin https://<BITBUCKET_USERNAME>:<APP_PASSWORD>@bitbucket.org/<WORKSPACE>/<REPO_NAME>.git

Happy Trying!

Isabelisabelita answered 23/7, 2022 at 1:37 Comment(0)
C
0

This issue is created in new Update. Please do below things.

  1. Then I opened my Bitbucket account.

  2. Then at the bottom left corner you will find an icon with your username's initials.

  3. Click on that and go to settings and click on Personal Settings

  4. In personal Settings, in the left panel you will find "access management"

  5. Under that you will find "app passwords"

  6. Click on that --> Then you will routed to create app password page There you can give the required permissions and create password (Note: You have to store that password somewhere as it will be displayed only once)

When you push the code to any repo...use your app password instead of your account password (No need to change any settings in the git_config file)

Crimea answered 30/5, 2022 at 7:44 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.