logIt Log Around The Clock

OpenSSH With Key

tags:

ssh-keygen -t dsa

Will generate a pair of public-private key (with type DSA) inside ~/.ssh/. Defaults are:

id_dsa

and

id_dsa.pub

The public key can be tranfered to other host with running sshd (ssh server). Default authorization key file used by sshd is ~/.ssh/authorized_keys (this can be configured from /etc/ssh/sshd_config). Append the generated id_dsa.pub to this file in remote host:

$ cat id_dsa.pub >> authorized_keys

My host with private key id_dsa can now ssh to remote host containing my public key in its authorized_keys file.


Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> <pre lang="" line="" escaped="">