sftp help

Hi,

I want to use sftp from windows command line to connect Linux server,But I want that username and password should be given in script along with server name which I can modify.

Is their any way so that I can prepare bat file inside that i can use username and password and servername.

Becuase I am having one common user on all servers.

Regards,

Manoj

The great thing about using sftp and so ssh is, that you can use keys and exchange the public keys to allow access for users without password and it's all encrypted. So you might just process a list with hostnames and usernames and keep the passwords out of it, which will be much safer.
I remember there was a Resource Kit for windows servers centuries ago, including awk and other nice *nix tools. But for DOS-Batch I can't help, sorry.
Maybe there is another subforum here which is more on topic.

You could, but it's not suggested.

Use a SFTP client like Bitvise Tunneller (for Windows) that allows you to perform SFTP tasks to remote Unix hosts in the same way (abeit some small differences with syntax) as you would going from Unix to Windows.

Link: Tunnelier: SSH Terminal, Tunneling and File Transfer Client