rastoboy has asked for the wisdom of the Perl Monks concerning the following question:
I hope you can forgive a question that isn't necessarily Perl related. I am forced to write a script that must log into a bastion server to log into *another* server to do stuff. I need to pass the root password to this script on the other machine.
On the local machine, I enter the password with no echo, and hold it in a variable in memory. I then ssh into the bastion host and execute another script there--and that's where I need to feed it the root password to the third box.
Simple, right? ;-)
I've contemplated sending it as an argument, but then it will show up in the process list. I've contemplated sending it over another socket, but that seems very complicated.
Any ideas?
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: Passing a password to another process "safely" in Linux
by belg4mit (Prior) on Jun 27, 2011 at 21:16 UTC | |
Re: Passing a password to another process "safely" in Linux
by chrestomanci (Priest) on Jun 27, 2011 at 21:24 UTC | |
Re: Passing a password to another process "safely" in Linux
by locked_user sundialsvc4 (Abbot) on Jun 29, 2011 at 12:48 UTC |