Hi,
I need to establish a 3des-cbc or blowfish-cbc connection
to a remote OpenSSH Version 2 Server (openssh.org) but
when I run my script in SSH debug mode the error that occurs is:
Enter your username on that host: root
And your password: rootpass
Perl Script is connection to 192.168.247.120
localhost.localdomain: Reading configuration data /root/.ssh/config
localhost.localdomain: Reading configuration data /etc/ssh_config
localhost.localdomain: Allocated local port 1023.
localhost.localdomain: Connecting to 192.168.247.120, port 22.
localhost.localdomain: Remote protocol version 1.99, remote software version OpenSSH_3.5p1
localhost.localdomain: Net::SSH::Perl Version 1.23, protocol version 2.0.
localhost.localdomain: No compat match: OpenSSH_3.5p1.
localhost.localdomain: Connection established.
localhost.localdomain: Sent key-exchange init (KEXINIT), wait response.
localhost.localdomain: Algorithms, c->s: 3des-cbc hmac-sha1 none
localhost.localdomain: Algorithms, s->c: 3des-cbc hmac-sha1 none
localhost.localdomain: Entering Diffie-Hellman Group 1 key exchange.
localhost.localdomain: Sent DH public key, waiting for reply.
localhost.localdomain: Received host key, type 'ssh-dss'.
localhost.localdomain: Host '192.168.247.120' is known and matches the host key.
localhost.localdomain: Computing shared secret key.
localhost.localdomain: Verifying server signature.
localhost.localdomain: Waiting for NEWKEYS message.
localhost.localdomain: Enabling incoming encryption/MAC/compression.
localhost.localdomain: Send NEWKEYS, enable outgoing encryption/MAC/compression.
localhost.localdomain: Sending request for user-authentication service.
localhost.localdomain: Service accepted: ssh-userauth.
localhost.localdomain: Trying empty user-authentication request.
localhost.localdomain: Authentication methods that can continue: publickey,password,keyboard-interactive.
localhost.localdomain: Next method to try is publickey.
localhost.localdomain: Next method to try is password.
localhost.localdomain: Trying password authentication.
root@192.168.247.120's password:
input must be 8 bytes long at /usr/lib/perl5/site_perl/5.8.0/i386-linux-thread-multi/Crypt/DES.pm line 57, <STDIN> line 6.
My perl script is:
my $ssh = Net::SSH::Perl->new($ip,protocol => '2', cipher => '3des-cbc', debug =>'1', interactive => '1');
$ssh->login($user||$this_user);
print("SSH connection established. User logged in.\n");
$ssh->cmd("ls -l");
... further commands ...
Any idea why the 3des-cbc does not work ?
If I start a ssh connection manually with
"ssh -2 192.168.247.120 -c '3des-cbc' -v" everythings
works fine.
All the needed packages (perl Modules) (Crypt::
...) are installed.
Any idea ? Thanks for your help
Markus
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.