Putting SSH keys I’ve taken from Ubuntu

Securitysshunix

I came over to Mac from Ubuntu. I've saved all SSH files I had in the .ssh folder in Ubuntu. There are three files

  • id_rsa
  • id_rsa.pub
  • known_hosts

Is it possible to reuse these files in Mac? If so, where do I put them?

Best Answer

You have to put them in the ~/.ssh/
OS X uses the same OpenSSH package as every other unix. Make sure you have set correct permissions, or ssh will not accept your keys

drwx------   5 user  staff   170 May 28 20:14 ./
-rw-------   1 user  staff  1679 May 19 14:19 id_rsa
-rw-r--r--@  1 user  staff   400 May 19 14:19 id_rsa.pub
-rw-r--r--   1 user  staff  6380 May 31 03:09 known_hosts