Skip Menu |
 

This queue is for tickets about the Net-SSH-Perl CPAN distribution.

Report information
The Basics
Id: 4648
Status: resolved
Priority: 0/
Queue: Net-SSH-Perl

People
Owner: Nobody in particular
Requestors: dan [...] midstream.com
Cc:
AdminCc:

Bug Information
Severity: Normal
Broken in: (no value)
Fixed in: (no value)



Content-Type: text/plain
Content-Disposition: inline
Content-Transfer-Encoding: binary
MIME-Version: 1.0
X-Mailer: MIME-tools 5.405 (Entity 5.404)
Subject: lib problem running simple command
X-RT-Original-Encoding: iso-8859-1
Content-Length: 2419
Download (untitled) / with headers
text/plain 2.3k
Net::SSH::Perl version: 1.24 perl version: 5.005_03 OS: SunOS sun-set 5.8 Generic_108528-13 sun4u sparc SUNW,UltraAX-i2 Installed and tested successfully of all required packages. I'm just doing ssh1 with DES3. Went to run my first test with the following code: ============================================== print "Choose a cipher from the list:\n"; my $supp = Net::SSH::Perl::Cipher::supported(); for my $ciph (sort @$supp) { printf " [%d] %s\n", $ciph, Net::SSH::Perl::Cipher::name($ciph); } printf "Enter a number: [%d] ", Net::SSH::Perl::Cipher::id('IDEA'); chomp(my $c = <STDIN>); print "\n"; my $ssh = Net::SSH::Perl->new($host, port => $port || 'ssh', cipher => Net::SSH::Perl::Cipher::name($c), debug => 1); $ssh->login($user, $pass); print "Enter a command to execute: [ls -l] "; chomp(my $cmd = <STDIN>); my($out, $err) = $ssh->cmd($cmd || "ls -l"); print $out; ============================================== Results follow... What should I do about the error at the end ? ====================================================== Choose a cipher from the list: [2] DES [3] DES3 [5] RC4 Enter a number: [1] 3 sun-set: Reading configuration data /root/.ssh/config sun-set: Reading configuration data /etc/ssh_config sun-set: Allocated local port 1023. sun-set: Connecting to 10.7.100.36, port 22. sun-set: Remote protocol version 1.99, remote software version OpenSSH_2.3.0 sun-set: Net::SSH::Perl Version 1.24, protocol version 1.5. sun-set: No compat match: OpenSSH_2.3.0. sun-set: Connection established. Enter a command to execute: [ls -l] sun-set: Waiting for server public key. sun-set: Received server public key (768 bits) and host key (1024 bits). sun-set: Host '10.7.100.36' is known and matches the host key. sun-set: Encryption type: DES3 sun-set: Sent encrypted session key. sun-set: Received encryption confirmation. class = Net::SSH::Perl::Auth type = RSA lib = Net/SSH/Perl/Auth/RSA.pm class = Net::SSH::Perl::Auth::RSA type = Net::SSH::Perl::SSH1=HASH(0x2976c) lib = Net/SSH/Perl/Auth/Net/SSH/Perl/SSH1=HASH(0x2976c).pm Can't locate Net/SSH/Perl/Auth/Net/SSH/Perl/SSH1=HASH(0x2976c).pm in @INC (@INC contains: /usr/perl5/5.00503/sun4-solaris /usr/perl5/5.00503 /usr/perl5/site_perl/5.005/sun4-solaris /usr/perl5/site_perl/5.005 .) at /usr/perl5/site_perl/5.005/Net/SSH/Perl/Auth.pm line 42. ======================================================
Return-Path: <autarch [...] urth.org>
Delivered-To: cpan-bug+net-ssh-perl [...] pallas.eruditorum.org
Received: from urth.org (unknown [65.103.28.217]) by pallas.eruditorum.org (Postfix) with ESMTP id 68AA811280 for <bug-Net-SSH-Perl [...] rt.cpan.org>; Thu, 11 Dec 2003 20:44:21 -0500 (EST)
Received: from autarch (helo=localhost) by urth.org with local-esmtp (Exim 4.22) id 1AUcLq-0002Bt-8a for bug-Net-SSH-Perl [...] rt.cpan.org; Thu, 11 Dec 2003 19:44:18 -0600
Date: Thu, 11 Dec 2003 19:44:18 -0600 (CST)
From: Dave Rolsky <autarch [...] urth.org>
To: Guest via RT <bug-Net-SSH-Perl [...] rt.cpan.org>
Subject: Re: [cpan #4648] lib problem running simple command
In-Reply-To: <rt-4648-13794.17.859933703453 [...] cpan.org>
Message-Id: <Pine.LNX.4.58.0312111944000.2387 [...] urth.org>
References: <rt-4648-13794.17.859933703453 [...] cpan.org>
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; charset=US-ASCII
RT-Send-Cc:
X-RT-Original-Encoding: us-ascii
Content-Length: 508
Download (untitled) / with headers
text/plain 508b
On Thu, 11 Dec 2003, Guest via RT wrote: Show quoted text
> Can't locate Net/SSH/Perl/Auth/Net/SSH/Perl/SSH1=HASH(0x2976c).pm in > @INC (@INC contains: /usr/perl5/5.00503/sun4-solaris /usr/perl5/5.00503 > /usr/perl5/site_perl/5.005/sun4-solaris /usr/perl5/site_perl/5.005 .) at > /usr/perl5/site_perl/5.005/Net/SSH/Perl/Auth.pm line 42.
This is almost certainly a bug in the code. I'll have to take a look at it. -dave /*======================= House Absolute Consulting www.houseabsolute.com =======================*/
Content-Type: text/plain
Content-Disposition: inline
Content-Transfer-Encoding: binary
MIME-Version: 1.0
X-Mailer: MIME-tools 5.415 (Entity 5.415)
X-RT-Original-Encoding: iso-8859-1
Content-Length: 552
Download (untitled) / with headers
text/plain 552b
Looks like part of the problem might have been fixed already but to fix the rest, Net::SSH::Perl::Cipher::supported can take a named 'protocol => $protocol' argument which returns SSH2-only ciphers for 'protocol => 2'. Also changed Net::SSH::Perl::Kex to automatically translate SSH1 cipher names to SSH2 names e.g. DES3 to 3des-cbc. This will make the program attached to this ticket work with the change that supported() must be supported(protocol => 2) (and the 'IDEA' default isn't supported under SSH2 so will fail). Above fix to go into 1.27.


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.