My GitHub ssh key is expired. I tried to update it, which works on GitHub's site, but my laptop just shows me the old RSA fingerprint when I try to push/pull/clone. So currently, my laptop has no access to GitHub now.
There a similar questions on StackOverflow (but they are not covering my case):
- How can I force ssh to accept a new host fingerprint from the command line
- How to generate ssh keys (for github)
- git clone through ssh
When I try to push/pull, following message appears
The authenticity of host 'github.com (140.82.121.4)' can't be established.
RSA key fingerprint is SHA256:xyz/0GFYZ+xPpuxU.
Are you sure you want to continue connecting (yes/no/[fingerprint])?
Hitting yes
results in having no access, because the fingerprint mentioned in the message is expired. Entering a new fingerprint
seems not to work, because the message just appears again.
For sure, I tried to update the ssh key. Undertaken steps:
- deleted the old ssh key on GitHub (Settings --> SSH and GPG keys --> [Ðelete] old key)
- created a new ssh key in my terminal with
ssh-keygen -o
~/.ssh/id_rsa
and~/.ssh/id_rsa
were updated- got my fingerprint, let's say
SHA265:abcdefg name@name-P452USF
- saved the ssh key on GitHub.
- message appears again after trying to pull/clone/push. Again the message shows the expired fingerprint
- deleted content of
~/.ssh/known_host
, because the expired fingerprint is stored here. - repeated steps 1-5
- message occurs again (why/where is expired fingerprint still stored???)
Rebooting my device does not work too.
Entering the new fingerprint does not work (why?). After hitting [Enter]
the message appears again.