Re: OpenSSH question : password prompt when scripting



Because you are switching your user to "pearson," you must verify that the
.ssh directory exists within pearson's $HOME directory, followed by
verifying that your id_rsa & id_dsa files are in there. I would also check
the $HOME/.ssh/authorized_keys file as well.

Also, what is the output from using the -v option as suggested by Enrique?


-----Original Message-----
From: IBM AIX Discussion List [mailto:aix-l@xxxxxxxxxxxxx] On Behalf Of
Enrique Sanchez Vela
Sent: Thursday, June 15, 2006 13:38
To: aix-l@xxxxxxxxxxxxx
Subject: Re: OpenSSH question : password prompt when scripting


--- "Yard, John" <jyard@xxxxxxxxxxxx> wrote:

On AIX 5.1 , using openssh, running as a user
I can do a key exchange, and will not be prompted
for a password :

$ sftp geles@xxxxxxxxxxxxxxxxxxxxxxx
Connecting to xxxasaprdftp.nc.ncs.com...
sftp> quit
$

But if I run the exact same command as a script,
it prompts me for a password:

[viper:/usr/local/bin] # su - pearson -c /usr/local/bin/get_Pearson
Connecting to xxxasaprdftp.nc.ncs.com...
gesles@xxxxxxxxxxxxxxxxxxxxxxx's password:


try running the ssh command with the -v option to
see more messages about key exchanges and
server-client interaction.

regards,
enrique.

Enrique Sanchez Vela
email: esanchezvela@xxxxxxxxx
--------------------------------------
http://www.savetheinternet.com/

__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com