Add hosts file content for GitHub's SSH keys
Code of Conduct
- [X] I have read and agree to the GitHub Docs project's Code of Conduct
What article on docs.github.com is affected?
https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/githubs-ssh-key-fingerprints
What part(s) of the article would you like to see updated?
The article lists the fingerprints for the various GitHub ssh keys. Unfortunately this requires users to manually and visually compare the fingerprints during the initial connection, which is an error-prone process. Instead, it would be more helpful if the article also provided the equivalent content for a known_hosts file, as gitlab does.
Additional information
Gitlab makes it much easier to import keys - they even include a copy button.
Thanks for opening this issue. A GitHub docs team member should be by to give feedback soon. In the meantime, please check out the contributing guidelines.
@Clockwork-Muse Thanks so much for opening an issue! I'll triage this for the team to take a look :eyes:
cc-ing @github/authentication for triage
Thanks @Clockwork-Muse , we'll get a PR open internally to make a few changes related to the issue you've raised here. Since we'll address this internally, I'll close this issue.
FYI @vgrl We made updates here as well.
The path in the documentation is missing a slash.
It currently is: ~.ssh/known_hosts
It should be: ~/.ssh/known_hosts
Great catch @Clockwork-Muse ! 🎉 You or anyone else is welcome to open new a PR with a quick fix 🔨 to address the missing slash in the file path on line 25.
Note also that we have frozen the docs repo over the holiday period, so PRs we won't be merging any changes until after Jan 3, 2023.