Post a reply

Options
Add an Attachment

If you do not want to add an Attachment to your Post, please leave the Fields blank.

(maximum 10 MB; please compress large files; only common media, archive, text and programming file formats are allowed)

Options

Topic review

martin

Re: How do you enter a password

open scp://username:password@192.168.1.21 -hostkey="ssh-rsa 1040 OPnZrsdw14pOWRif......."
Guest

How do you enter a password

Hi
I am really really new to this and but I am trying to write a script that will untimely sync some files between some networking equipment and my desktop...
this is what I get in the log file...
Searching for host...

Connecting to host...
Authenticating...
Username: Password:
Connection has been unexpectedly closed. Server sent command exit status 0.
Authentication failed.


this is what my Script looks like
open scp:192.168.1.21 -hostkey="ssh-rsa 1040 OPnZrsdw14pOWRif......."
<my switch>
<password>
cd /tmp
ls
put c:\junk\test.txt
ls
close
exit

this is how I start the script
[code]@batch@
"C:\Program Files (x86)\WinSCP\winscp.com" /ini=nul /script=c:\junk\testscr.txt >log.txt
[/cide]

What I am doing wrong... I do not know how to deal with the password....
any other suggestions would be welcome

thanks
Gary