Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 20 Jul 2002 12:09:40 HST
From:      Gary Dunn <gdunn@mac.com>
To:        thrawn@linux.nu, freebsd-questions@FreeBSD.ORG
Subject:   Re: Expect script problem with ssh login
Message-ID:  <20020720220940.BE9CFB377@vaiosr7k.ozland>
In-Reply-To: <3d39d3689a81a4.61372381@not right>

index | next in thread | previous in thread | raw e-mail

On Sat, 20 Jul 2002 23:17:28 +0200, Mattias Björk wrote:
> 
> Hi, I have a expect script that I have some problems with.
> 
> What I want to use this script is simply logon me on another machine and
> enter the password when ssh prompts for it.And then give me a shell as I
> Will manuly ssh to the host.
> 

An easier and more secure way to get this functionality is to use the public key feature. Generate a public-private key pair (ssh-keygen, I believe). There are two protocols to contend with, and one requires a flag like -d. Copy the *public* key to the remote host, append to the appropriate authorized keys file in ~/.ssh there. 

When it's all set up just ssh <remote-host> and you're in. If you feel that your user account is not very secure you can choose to have your private key encrypted, but then you always have to enter the passphrase, which brings you back to were we began.

 --+---+---+--
Gary Dunn
Open Slate Project
http://www.aloha.com/~knowtree/



To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message



help

Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20020720220940.BE9CFB377>