Sshkeys

From Wiki

(Difference between revisions)
Jump to: navigation, search
(change from dsa to rsa to make ssh keys work again after server upgrades.)
 
Line 2: Line 2:
Create keys on local machine
Create keys on local machine
-
  ssh-keygen -t dsa
+
  #ssh-keygen -t dsa   Will not work anymore after server upgrades
 +
ssh-keygen -t rsa
Copy Public Key (id_dsa.pub) to PC you want to log into
Copy Public Key (id_dsa.pub) to PC you want to log into
-
  scp ~/.ssh/id_dsa.pub username@host:
+
  scp ~/.ssh/id_rsa.pub username@host:
On the PC you want to log into go to the .ssh folder in the home dir and add the key in to the authorised keys file
On the PC you want to log into go to the .ssh folder in the home dir and add the key in to the authorised keys file
-
  cat id_dsa.pub >> authorized_keys
+
  cat id_rsa.pub >> authorized_keys
Thats it. The pub key can be deleted off the server. Job Done.<br>
Thats it. The pub key can be deleted off the server. Job Done.<br>
Original = http://www.redbrick.dcu.ie/help/tutorials/ssh_keys/
Original = http://www.redbrick.dcu.ie/help/tutorials/ssh_keys/

Current revision as of 08:05, 25 May 2018

Creating SSH Keys for rsync or ssh etc.

Create keys on local machine

#ssh-keygen -t dsa   Will not work anymore after server upgrades
ssh-keygen -t rsa

Copy Public Key (id_dsa.pub) to PC you want to log into

scp ~/.ssh/id_rsa.pub username@host:

On the PC you want to log into go to the .ssh folder in the home dir and add the key in to the authorised keys file

cat id_rsa.pub >> authorized_keys

Thats it. The pub key can be deleted off the server. Job Done.
Original = http://www.redbrick.dcu.ie/help/tutorials/ssh_keys/

Personal tools