2

This is my first time dealing with ssh keys and github as a new developer.
Every time I've tried to connect an ssh key to my Mac Terminal, this message pops up:

The authenticity of host 'github.com (140.82.114.3)' can't be established.
ECDSA key fingerprint is SHA256:p2QAMXNIC1TJYWeIOttrVc98/R1BUFWu3/LiyKgUfQM.
Are you sure you want to continue connecting (yes/no)? 

The fingerprint pasted in the GitHub website never matches the fingerprint in the message.
I followed all of the instructions as I saw them.
Any ideas on what I could do to fix this?

VonC
  • 1,262,500
  • 529
  • 4,410
  • 5,250
techgoddes23
  • 21
  • 1
  • 3
  • The ECDSA-fingerprint matches the one provided from github. Have a look [here](https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/githubs-ssh-key-fingerprints). Therefore you can continue by typing `yes`. – Mime Aug 11 '22 at 12:18

1 Answers1

2

Warning March 2023:

"GitHub updated their RSA SSH host key".


If the output of ssh-keyscan github.com matches the official GitHub's SSH key fingerprints, you can go ahead and type:

ssh-keyscan github.com >> ~/.ssh/known_hosts

That way, SSH should not query you anymore about the authenticity of host 'github.com.

From there, any SSH key added to your GitHub account profile should work, which you can check with:

ssh -Tv git@github.com
VonC
  • 1,262,500
  • 529
  • 4,410
  • 5,250