Script with Password

Advertisement

RealDeal
Joined:
Posts:
1
Location:
Calgary

Script with Password

Hi There,

I am creating a simple script to download some files from an SFTP server. I need to automate this so will use Windows for that. How do I input the password for the SFTP server? I always getting prompted when I run the .bat which just calls the .txt file.

run.txt =
open <Session Name>
synchronize local "C:\SFTPtest" "/"
exit

run.bat =
C:\Progra~2\WinSCP\WINSCP.exe /console /script=run.txt

It works, just prompts me for the password everytime. I also have the option of Private key and passphrase...how can I script that? New to all this.

Thanks
RD.

Reply with quote

Advertisement

Advertisement

You can post new topics in this forum