OpenSource For You

Key-based authentica­tion

-

1Rw, OHW’V find RXW hRw WR VHW XS 66H SXEOLF NHy authentica­tion to log in without passwords. This involves several steps. First, run these on host A, from which you want to log in to host B: $ ssh-keygen -t dsa <Keep empty private key password> $ cat ~/.ssh/id_dsa.pub | ssh hostB “cat >> ~/.ssh/authorized_ keys”

With this, the public key on A should be appended to the ~/.ssh/authorized_keys fiOH Rn hRVW B. 1HxW, VHW XS WhH sshagent daemon and use the ssh-add command to load the key. On host A, use the following commands: $ eval `ssh-agent -s` $ ssh-add $ ssh-add -l (SKRULD LLST YRUR KEY fiNGERPRLN­T)

Now you are all set. If you log in on host A, you can talk to the remote machine without passwords; in place of this, your private key authentica­tes you to the other host. Instead of laboriousl­y typing passwords, this lets you log in with the private key’s password just once, and use the key for multiple remote logins. This is a bit complex, so please try it a few times to get it right.

Newspapers in English

Newspapers from India