Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

hide password prompt... #3

Closed
masavini opened this issue Jun 26, 2019 · 3 comments
Closed

hide password prompt... #3

masavini opened this issue Jun 26, 2019 · 3 comments

Comments

@masavini
Copy link

masavini commented Jun 26, 2019

hi,
is it possibile to hide the password prompt just like sshpass does?
this is kind of an issue mostly when redirecting command output...
example:

$ passh -p password user@host pwd > out
$ cat out
user@host's password:
/home/user
$
$ sshpass -p password user@host pwd > out
$ cat out
/home/user
@masavini
Copy link
Author

just found a forker who just did that:
brunomgalmeida@63e3c03#diff-0d215611d71266122acf1cb3dc742ca0

@clarkwang
Copy link
Owner

clarkwang commented Jun 26, 2019

just found a forker who just did that:
brunomgalmeida@63e3c03#diff-0d215611d71266122acf1cb3dc742ca0

That'll not solve all the problems. With passh, in the output all NEWLINEs will be \r\n instead of \n (this is how a pty works by default). And just like sshpass its kind of a hack. Personally I'd handle the output on my own requirement.

@masavini
Copy link
Author

masavini commented Jun 26, 2019

you right, i didn't notice that..
even more, brunomgalmeida's passh version prints no output when it should contain just one line:

$ # clarkwang
$ passh -p password user@host pwd > t
$ cat t
user@host's password:
/home/user
$
$ # brunomgalmeida
$ passh -q -p password user@host pwd > t
$ cat t
$

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants