[SWLUG] using ssh to talk to a server?

Paul G. Richardson p.g.richardson at phantomjinx.co.uk
Fri May 2 12:49:44 UTC 2008


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Mark Summerfield wrote:
| On 2008-05-02, Justin Mitchell wrote:
|> On Fri, 2008-05-02 at 11:44 +0100, Mark Summerfield wrote:
|>> What I'd really like it to be able to make both machines "trust" each
|>> other, but without that trust extending past the router that they are
|>> connected by (and that is connected to the Internet).
|>>
|>> Could I create a ~/.ssh/ssh_config file or some such on each machine to
|>> do that?
|> you can make an account on one machine be able to login to the other
|> without a password.
|>
|> on the 'from' machine first run ssh-keygen, just hit enter to its
|> questions, and dont set a password otherwise youve just moved the
|> problem.
|>
|> this will create ~/.ssh/id_rsa and id_rsa.pub
|>
|> copy the contents of id_rsa.pub from the local machine and add it to the
|> end of ~/.ssh/authorized_keys on the target machine. create the file if
|> you have to.
|>
|> now whenever you ssh from an account that has the ~/.ssh/id_rsa file,
|> into an account that has the ~/.ssh/authorized_keys file, it wont ask
|> for a password.
|>
|> copy those files to any other accounts/machines that you need this to
|> work for.
|
| I already had thos rsa files (I think I had to generate them to be
| allowed to edit the Python docs), but I didn't know what they were for.
|
| Now I've make authorized_keys files on both my machines with the others'
| id_rsa.pub contents---and it works a treat, ssh with no passwords:-D
|
| One last question though: how do I use names instead of IP addresses so
| I can write
|     ssh percival
| instead of
|     ssh 192.168.2.3
| etc?
|
| Thanks!
|
|

add to /etc/hosts

192.168.2.3 percival

save.
job done.

PGR

- --
P.G. Richardson

Email: p.g.richardson at phantomjinx.co.uk

- ---

"There is no present or future, only the past
happening over and over again now."
Eugene O'Neille

"History is the nightmare from which I am trying
to awake."
James Joyce

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.7 (GNU/Linux)

iD8DBQFIGw3gcthLMIwdEb0RAki8AKDdo9KnzBmiJWGDn+zaVj1qGn56nwCdFuNf
017qYH5ArzYhlZQJ81sxksg=
=tx9a
-----END PGP SIGNATURE-----



More information about the Swlug mailing list