sshpass does not report file not found with -v -f, instead hangs
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
apt (Ubuntu) |
New
|
Undecided
|
Unassigned |
Bug Description
Using sshpass to send a password to ssh-add
When I use a valid file path and give command :
I get the expected output
SSHPASS searching for password prompt using match "pass"
SSHPASS read: Enter passphrase for /home/tushar/
SSHPASS detected prompt. Sending password.
SSHPASS read:
Identity added: /home/tushar/
But when I use :
sshpass -v -f /home/tushar/
Where I have mistakenly put an incorrect path or file name, it does not report that the file does not exist, should do that first, instead if continues with issuing the command, looks for the text marker per -P and then tries to give it the password, and then hangs, as I guess there is no password to give and ssh-add keeps waiting. No error or warning emited.
Output:
SSHPASS searching for password prompt using match "pass"
SSHPASS read: Enter passphrase for /home/tushar/
SSHPASS detected prompt. Sending password.
* After this command does not complete, hangs here