SSH command in unix

ssh command takes the password only from stdin. It does not accept the password
from files. I tried the following method to pass the password to ssh through file. But, it does not worked.

mohanraj@ltsp63:~/Unix$ ssh mohanraj@server < pass
Pseudo-terminal will not be allocated because stdin is not a terminal.
mohanraj@server's password:

mohanraj@ltsp63:~/Unix$

Here, “pass” is the file which contains the password.


Source: shell

Leave a Reply