SFTP without password and without public/ private key
Hi,
I am new to the whole linux scripting word but I have requirement where I have to write small script for doing SFTP without using public/ private key.
I tried following script but expect is not working. can some one help me with this.
#!/bin/sh
#!/usr/local/bin/expect
echo "Starting"
expect "password:"
sftp -b batchfile$1@$2 <<EOF
send "A4zNC3mZHv](\n"
cd $3
put $4
bye
EOF
Thanks,
Akshay
|