Eliminating password prompts from ssh & scp

Allan Metts ametts2 at mindspring.com
Wed Dec 10 21:07:44 UTC 2003


Hi all,

I have a silly little problem that has cost me an inordinate amount of time.

I need to spawn a secure file transfer from within a C program.  I'd like 
to simply execute the appropriate scp statement and capture the return code 
-- should be no problem.

Here's the silly part:  I can't find a way to prevent scp from prompting me 
for a password.  I've messed with sshd_config, established RSA1 keys, and 
done everything else I can think of.  And there seems to be no way to 
include the password on the scp command line.  I really don't want to have 
to set up chat or expect logic just to deal with the password prompt.

I've got to be overlooking something basic, but I'll be darned if I can 
figure out what.  Can someone set me straight?  If not, does anyone know of 
an easy-to-use C++ API wrapper for scp/sftp?

Thanks in advance,
Allan





More information about the fedora-list mailing list