There have been three file formats for SSH keys. According to PuTTY document, "SSH-2 private keys have no standard format."
- OpenSSH format
- PuTTY's native format(*.PPK)
- SECSH format, RFC4716
- ssh-keygen
- "Git for Windows" contains it.
- PuTTYgen
- "WinSCP(package version)" and "SourceTree for Windows" contain it.
- Tera Term
- SSHの秘密鍵について - 禿散らかしてごめんなさい (in Japanese)
- Generating SSH keys, GitHub Help
###Convert SECSH(RFC4716) format to others This is quoted from http://qiita.com/marcie001/items/47a23cfeed00db783d39 (in Japanese).
$ ssh-keygen -i -f id_rsa.pub >> ~/.ssh/authorized_keys
###Identify a size of SSH key This is quoted from http://d.hatena.ne.jp/hnw/20140705 (in Japanese).
$ ssh-keygen -l -f $HOME/.ssh/id_rsa.pub
This is quoted from http://d.hatena.ne.jp/MIZUNO/20080705/1215238138 (in Japanese).
$ ssh -i ~/.ssh/id_rsa.hoge [email protected]
The ssh command searchs SSH keys automatically if the SSH keys are set in ~/.ssh/config.
IdentityFile ~/.ssh/id_rsa
IdentityFile ~/.ssh/id_rsa.hoge
IdentityFile ~/.ssh/id_rsa.foo