Hi All,
We are in the process of changing our File transfers to Secure mode using SecureShell.
We already have scripts to Do File transfer using FTP client (i.e, non secure mode) and
iam giving one example, which explains how we automate regular
FTP.
Now we are changing all of them to SFTP or Secure transfer mode/encrypted.
Our old regiular scripts are some thing like this
ftp -n -i -v
ftp.url.com <<!
user username password
cd /data/shared/
lcd /data/import
mget vcm*.dat
bye
!
In this case, we are giving the password directly or as an argument or in a batch file.
Coming to SFTP,by using -B option(Batch file)
SFTP -B /devl/test.batch user@
ftp.url.comtest.batch contains the following data.
user_password
pwd /user/data/shared
get vcm_today.dat
quit
SFTP exceuting the password as a command and coming out as a Bad command.
My question is
How to Automate the SFTP Scripts by passing Password as an argument or in a File.
Responses are highly appreciated.
Thanks in advance,
Rad