- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - Linux
- >
- Re: yet another ssh and pass password problem
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО06-28-2007 03:59 AM
тАО06-28-2007 03:59 AM
yet another ssh and pass password problem
I am struggeling to pass a password to an ssh-call.
Yes, I know, .... use keys and agent and ...
This does not work in this specific case, because the box I need to connect to is an embedded Linux System (a router), on which I can not (!) configure any ssh-server parameter, nor do I have a home directory to store keys in. You plain log in and have a set of commands to administrate this box.
I have a windows based solution using puttys plink, which has a "-pw" option to pass a password in the commandline. I do not like this at all, but there is no other way.
I'd like to have a solution in which I use ssh on Linux to do this.
Calling ssh with "-v" shows "password" as the only valid authentication method on the server side, and again, I can not change this.
I am on Red Hat 2.6.9-42
OpenSSH_3.9p1
Piping does not work, i.e.
echo "mypass" | ssh ....
This way :
ssh ... <
exit
EOF
gives a reasonable result, but still requires to enter the password interactively, before my command is executed.
Is there a way to set up the ssh-agent to forward a password instead of a key ?
Help is very welcome
Volker
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО06-28-2007 04:06 AM
тАО06-28-2007 04:06 AM
Re: yet another ssh and pass password problem
http://www.thescripts.com/forum/thread49599.html
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО06-28-2007 04:42 AM
тАО06-28-2007 04:42 AM
Re: yet another ssh and pass password problem
The other end won't let you place a public key as authorized_keys file?
Assuming there is trust, this would work.
Scripted ssh has the same issue as putty, its not safe.
SEP
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-01-2007 09:57 PM
тАО07-01-2007 09:57 PM
Re: yet another ssh and pass password problem
after a bit of trouble getting the module and the depended MATH module installed,
I get at least a connection.
But my command is not executed. (output as follows:)
Entering interactive session.
Sending command: show status isdn
Requesting service exec on channel 1.
channel 1: open confirm rwindow 0 rmax 32768
Remote:
The script hangs with this "Remote:" prompt and does nothing further, until I do an abort.
I found some issues with other routers having special ssh implementations which do not allow the use of two channels.
The very same script directed to a linux box doing an "ps -ef" works fine.
my $ssh = Net::SSH::Perl->new($host,debug=>1,protocol=>2,use_pty=>1);
$ssh->login($user, $pass);
($out, $err, $exit)=$ssh->cmd('show status isdn');
print "-- $out\n";
print "== $err\n";
Any idea how to proceed further ?
Volker
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-01-2007 10:16 PM
тАО07-01-2007 10:16 PM
Re: yet another ssh and pass password problem
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-30-2007 07:24 AM
тАО07-30-2007 07:24 AM
Re: yet another ssh and pass password problem
I got a workaround using plink from putty on a windows box and I am able to pass the password as a parameter.
Volker