4 ms·
`ssh-keyscan -t rsa github.com | ssh-keygen -lf -` gives you the fingerprint for github.com. Save this key, and reuse it everywhere before connecting to github
by kakarot 8y ago
`ssh-keyscan -t rsa github.com | ssh-keygen -lf -` gives you the fingerprint for github.com.
Save this key, and reuse it everywhere before connecting to github.
Now the issue of being MITM'd is once again only an issue with your very first connection, which is done via ssh-keyscan.
As for your other servers, you should only check the host key once for any of them, and then save it. And that's only if they are owned by a third-party, like a shared server. If your provider routinely cycles host keys, get a new provider who actually cares about security.
If these servers are owned by your employer, then your employer needs better security practices and, failing a certificate authority, should provide you with the necessary host fingerprints before you ever connect to a box.
- dancek 8y agoI currently check fingerprints on first connection and then save them. They're available for most servers, including github and other git providers. I think I've only had to connect to one server without knowing the fingerprint in advance in the last couple of years. Looks to me like the fingerprint-checking process has to be manual if you can't choose the server certificate.