Hi Team,
When i try to push code using git push cmd, I'm getting below error:
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@ WARNING: REMOTE HOST IDENTIFICATION HAS CHANGED! @
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
IT IS POSSIBLE THAT SOMEONE IS DOING SOMETHING NASTY!
Someone could be eavesdropping on you right now (man-in-the-middle attack)!
It is also possible that a host key has just been changed.
The fingerprint for the RSA key sent by the remote host is
SHA256:46OSHA1Rmj8E8ERTC6xkNcmGOw9oFxYr0WF6zWW8l1E.
Please contact your system administrator.
Add correct host key in /home/manju/.ssh/known_hosts to get rid of this message.
Offending RSA key in /home/manju/.ssh/known_hosts:5
remove with:
ssh-keygen -f "/home/manju/.ssh/known_hosts" -R "bitbucket.org"
RSA host key for bitbucket.org has changed and you have requested strict checking.
Host key verification failed.
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
Then i ran a cmd as below:
git ls-remote -h git@bitbucket.org:manjunathbv/cirrus-erp.git HEAD
After above cmd, i got the same worning and now when i push code i get a msg:
Warning: the ECDSA host key for 'bitbucket.org' differs from the key for the IP address '2406:da00:ff00::22cd:e0db'
Offending key for IP in /home/manju/.ssh/known_hosts:21
Matching host key in /home/manju/.ssh/known_hosts:29
Are you sure you want to continue connecting (yes/no)?
could you please help me with the same?
This is a classic SSH host key mismatch issue. It usually happens when:
known_hosts.The important thing is to verify the new key is legitimate before accepting it.
Initially SSH reported:
After running additional commands, SSH now sees:
This means your known_hosts file contains entries for both:
bitbucket.org2406:da00:ff00::22cd:e0dband they don't match.
Remove the old Bitbucket entries:
Or manually edit:
and delete the offending lines (21 and any old Bitbucket entries).
Test the connection:
You should get something similar to:
Before typing yes, compare the fingerprint shown with the official Bitbucket SSH fingerprints published by Atlassian:
https://support.atlassian.com/bitbucket-cloud/docs/configure-ssh-and-two-step-verification/
If the fingerprint matches Atlassian's documentation, type:
This will create a fresh entry in ~/.ssh/known_hosts.
Run:
You should see a successful authentication message.
Then try:
again.
Please share the output of:
and
(with any sensitive information removed), and I can pinpoint exactly which host key entry is causing the conflict.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.