When I go to the SSH keys page in my GitHub account, I see a key whose identity starts with "c5:42:08:9d:39:22..."
On my computer, in the ".ssh" folder, I have several files that look like public SSH keys, but none of them contains a string similar to the above. For example, one of the files "id_rsa.pub" contains a string that starts with "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABA..." there are other similar files that probably represent different keys.
How can I identify which of the files, if any, represents the actual key that is in my github account?
"c5:42:08:9d:39:22...
" isn't the key, but rather the key's fingerprint. You can see your key's fingerprint using ssh-keygen
:
ssh-keygen -lf ~/.ssh/id_rsa
Where
-l
means we want to see the key's fingerprint-f ~/.ssh/id_rsa
is a path to the key whose fingerprint we want to seeOn older versions of OpenSSH, you may need to also specify that you want the SHA256 fingerprint rather than another hash like MD5, since SHA256 is what GitHub shows in its web interface:
ssh-keygen -lf ~/.ssh/id_rsa -E sha256
You should get the same fingerprint from the public part as from the private part of the keypair.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With