Net::SSH2 - Authentication without a password?

C

CsB

I have installed Net::SSH2 installed and use it to connect to 90% of
the networking equipment I need to access. It works great, thank you
to zentara for the suggestion.

However, I'm trying to find a solution for one vendor that decided to
be different from the others.

For arguments sake, we'll call the vendor 'alpha'.

Alpha equipment apparently requires an SSH login name but no password.

When I use SecureCRT to connect to one of the alpha boxes, (using
Keyboard Interactive or Password as the authentication method) I am
prompted for a username. Once I enter the proper username, the SSH2
session is established, a shell is started, and I am then presented
with a new set of userid and password requests which are authenticated
against our RADIUS servers. It never prompts me for a password to
accompany the initial username request. I have confirmed (with the
administrator of this equipment) that it doesn't require a password to
establish the SSH2 session.

I cannot find many examples of Net::SSH2 so I have struggled to find
an answer. While reading through the docs, I have tried various
options including:

$ssh2->auth_password( 'username' ) or die "Unable to login $@ \n";

$ssh2->auth_password( 'username', '' ) or die "Unable to login $@ \n";

$ssh2->auth_keyboard( 'username' ) or die "Unable to login $@ \n";

$ssh2->auth_list( username );
(then checking the value of $ssh->auth_ok

All have failed. I cannot seem to figure out how to emulate the login
process executed by SecureCRT.

Any suggestions would be greatly appreciated.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,755
Messages
2,569,534
Members
45,007
Latest member
obedient dusk

Latest Threads

Top