timecatalyst has asked for the wisdom of the Perl Monks concerning the following question:
Technically, the error I'm seeing is from Net::SSH::Perl, but it cropped up through use of Net::SFTP.
I have a very small script that I'm using to test connectivity with an SFTP server:
However, there seems to be a problem with this that I have been unable to track down so far:#!/usr/bin/perl -l use strict; use Net::SFTP; my ( $host, $user, $pass ) = ( ... ); my $sftp = Net::SFTP->new( $host, user => $user, password => $pass, ssh_args => [ debug => 1 ] );
%perl sftp_test.pl Reading configuration data /usr/home/*****/.ssh/config Reading configuration data /etc/ssh_config Connecting to *************, port 22. Remote version string: SSH-2.0-VShell_2_3_1_151 VShell Remote protocol version 2.0, remote software version VShell_2_3_1_151 + VShell Net::SSH::Perl Version 1.30, protocol version 2.0. No compat match: VShell_2_3_1_151 VShell Connection established. Sent key-exchange init (KEXINIT), wait response. Algorithms, c->s: 3des-cbc hmac-sha1 none Algorithms, s->c: 3des-cbc hmac-sha1 none Entering Diffie-Hellman Group 1 key exchange. Sent DH public key, waiting for reply. Received disconnect message: Invalid packet header. This probably ind +icates a problem with key exchange or encryption. at /usr/local/lib/p +erl5/site_perl/5.8.4/Net/SSH/Perl/Kex/DH1.pm line 41
I am able to connect to the server through the sftp command line utility just fine. The module usage seems to be pretty straight-forward, but I suppose I could be missing something. I've tried passing it both SSH1 and 2, and all of the compatible cyphers for each through 'ssh_args', but with no luck.
If anyone more experienced than I with Net::SFTP or Net::SSH::Perl could shine some light on this for me, that would be most excellent.
-Andy
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Net::SFTP 'invalid packet header'
by zentara (Cardinal) on May 05, 2008 at 16:48 UTC | |
|
Re: Net::SFTP 'invalid packet header'
by pileofrogs (Priest) on May 05, 2008 at 16:43 UTC | |
|
Re: Net::SFTP 'invalid packet header'
by timecatalyst (Acolyte) on May 05, 2008 at 16:53 UTC | |
by pileofrogs (Priest) on May 05, 2008 at 17:47 UTC | |
by moklevat (Priest) on May 06, 2008 at 12:54 UTC | |
by salva (Canon) on May 07, 2008 at 08:09 UTC |