Just a heads up: On March 24, 2025, starting at 4:30pm CDT / 19:30 UTC, the site will be undergoing scheduled maintenance for a few hours. During this time, the site might be unavailable for a short while. Thanks for your patience.

×
Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Unable to get Recovery Codes for 2FA

Humberto Linero Fuentes
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
July 11, 2018

Hello,

The background:

> My bitbucket account has 2FA, I use google to sign in and at this moment I do not have access to my phone nor my recovery keys.  However, I do have the computer with the SSH keys of my bitbucket account.

The problem:

> I am running the command ssh git@bitbucket.org recovery_codes in order to generate some recovery keys and be able to access my account however, after putting my google password (remember I sign in to my account with google) I get the following response:

Because your Atlassian account admin requires single sign-on, you'll need to authenticate with an app password. Create an app password at https://bitbucket.org/account/admin/app-passwords

The problem is that to generate an app password I need to access my bitbucket account; however, I cannot access my account. Therefore, what do I do at this point?

 

Thank you for the help

9 answers

0 votes
bacvsee
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
November 15, 2019

image.pngI logged in successfully but got no recovery codes. Not sure what happen with my account???

0 votes
markoengelmanchipolo
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
May 24, 2019

@Ana Retamal I've run into the exact same problem as Humberto and others before me. Can you please help or provide further instructions how to act?

0 votes
Maxim Leonov
Contributor
March 12, 2019

@Ana Retamal I ended up in the same situation.

Opened BBS-101888 with Atlassian Support system.

Would it be possible to expedite it as I am currently locked out and unable to work?

 

Thanks.

Ana Retamal
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
March 14, 2019

Hi @Maxim Leonov , I've seen that one of my colleagues is already providing assistance. Do you need anything else?

Kind regards,

Ana

Maxim Leonov
Contributor
March 14, 2019

Yes, we are following it through. I am eagerly waiting for the recovery link as I am unable to work. It's technically been more than 48 hours since the email notifying that the recovery link has been sent.

Maxim Leonov
Contributor
March 14, 2019

I have recovered the access now.
Thanks.

Like Ana Retamal likes this
Ana Retamal
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
March 15, 2019

Thanks for the update, glad you can access now.

Have a good day!

Ana

0 votes
John Cotter January 7, 2019

Hi, 

Has there been any update or resolution to this issue? I have a team member in this exact situation and would appreciate any feedback, 

 

Thank you,. 

rahultiwari92
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
January 7, 2019

Yes, After completely understanding the situation, atlassian guys had sent an one time password reset link. I was then able to get my account back.

John Cotter January 8, 2019

Thanks Rahul, 

Just to clarify this is referring to a situation where the user has their SSH key, but is using google SSO (as opposed to a bb password) when attempting to get the recovery codes for access?

0 votes
rahultiwari92
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
December 7, 2018

Same issue here:, While recovering the codes IT keeps on saying:

Because your Atlassian account admin requires single sign-on, you'll need to authenticate with an app password. Create an app password at https://bitbucket.org/account/admin/app-passwords

The problem is that to generate an app password I need to access my bitbucket account; however, I cannot access my account. Therefore, what do I do at this point?

Have created a ticket as well BBS-94918 Urgent | Account not accessibleCapture.JPG

Becki Arieli
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
August 13, 2019

Hello, I have  exactly the same issue, opened ticket

Kamlesh Kumar
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
May 11, 2020

Hi Dear, I have also facing the same issue, opened ticket

0 votes
Alejandro Corbellini
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
October 20, 2018

@Ana Retamal same issue here, trying to get my recovery codes and getting an invalid password error. thanks!

0 votes
Ammad Hussain
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
August 7, 2018

@Ana Retamal facing a similar problem. I have keys of my bitbucket account and i can push/pull without any issues. when trying to recover codes via "

ssh git@bitbucket.org recovery_codes

im getting Invalid username or password error. would you please address the issue. Don't have my old phone which had 2f configured.

Ana Retamal
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
August 8, 2018

Hi @Ammad Hussain, as I said in the question you submitted, I've created a Support ticket for you, you'll receive an email notification soon!

Cheers :)

Ana

0 votes
droo
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
July 11, 2018

@Ana Retamal I've run into the exact same problem as Humberto. How can I be helped / added to that ticket?

Thanks,

Andrew

Ana Retamal
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
July 13, 2018

Hi @droo! Addressing this issue with you privately now :)

Cheers,

Ana

0 votes
Ana Retamal
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
July 11, 2018

Hi Humberto, welcome to the Community!

To assist you with this issue I've created a Support ticket for you, you should receive a notification about it shortly. One of my colleagues will contact you and help you solve this. 

If you have any other questions, please let us know! We're happy to help :)

Kind regards,

Ana

droo
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
July 11, 2018

@Ana Retamal Ortiz I've run into the exact same problem as Humberto. How can I be helped / added to that ticket?

Thanks,

Andrew

(re-pasted here as a reply, not an answer to humberto's question)

Humberto Linero Fuentes
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
July 11, 2018

Thank you, @Ana Retamal .

I am looking forward for the help with this issue.

 

--

Humberto

Ana Retamal
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
July 13, 2018

Hi @Humberto Linero Fuentes, I just talked to my friends from the Bitbucket Cloud team and they confirmed they'll reach out to you shortly :) 

Cheers!

Ana

cristelledoong January 14, 2019

Hi, @Ana RetamalI’m trying to run this command `ssh git@bitbucket.org recovery_codes` but I keep getting this response `git@bitbucket.org: Permission denied (publickey).` even if I have SSH key on my bitbucket. Now I can’t open my bitbucket account anymore. Please help me.

Ana Retamal
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
January 15, 2019

Hi @cristelledoong, you said you had the SSH key on your Bitbucket, but can you confirm you have the other part of the SSH key in your computer? Otherwise, Bitbucket won't be able to authenticate. You can run the following command to see if your machine can authenticate to the right username:

ssh -T git@bitbucket.org

And this other command to see the SSH key that your machine is offering:

 ssh-add -L

Let us know!

Ana

cristelledoong January 15, 2019

This is the response:

$ ssh -T git@bitbucket.org
git@bitbucket.org: Permission denied (publickey).

and

$ ssh-add -L
Could not open a connection to your authentication agent.

What should I do with it? Is there any way out?

John Cotter January 15, 2019

In a shell (or CLI) try

ssh-add -l

 If you get a message saying "you agent has no identities" try

ssh-add ~/.ssh/<private_key>

 Then try to ssh to bitbucket.

Ana Retamal
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
January 15, 2019

HI @cristelledoong,

Seems like the private part of your SSH key is not in your computer, or your SSH agent can not find it. Can you confirm you have the other part of the SSH key in your computer? 

If you're sure you have it, then you can follow the steps in the section Your identity isn't loaded into your SSH agent from the article Permission denied publickey.

If you are in a different computer, or you formatted it or lost your SSH key, you won't be able to get recovery codes. Please, let us know if this is your case.

Kind regards,

Ana

cristelledoong January 15, 2019

Hi @John Cotter and @Ana Retamal, this is the response:

$ ssh-add -l
The agent has no identities.
$ ssh-add ~/.ssh/SSHKEY_PVT.ppk
Error loading key "/c/Users/admin/.ssh/SSHKEY_PVT.ppk": invalid format

 The key is loaded to Pageant as well

image.png

cristelledoong January 15, 2019

Nevermind, guys. I already fixed it.

> From SourceTree I loaded my SSHKEY_PVT.ppk, then on Conversion menu, I clicked the Export to Openssh file format. It will create a new file format. I named it id_rsa_pvt.

> I entered this command:

$ ssh-add ~/.ssh/id_rsa_pvt
Enter passphrase for /c/Users/admin/.ssh/id_rsa_pvt:
Identity added: /c/Users/admin/.ssh/id_rsa_pvt (/c/Users/admin/.ssh/id_rsa_pvt)

> then entered this command after:

ssh git@bitbucket.org recovery_codes

> I got my recovery codes now!

Ana Retamal
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
January 16, 2019

Glad you sorted it out, @cristelledoong :D And thanks for sharing your solution with the rest of users!

Have a nice evening,

Ana

Like cristelledoong likes this

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events