Skip Menu |

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

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

People
Owner: schwigon [...] cpan.org
Requestors: adrian.koszorus [...] nokia.com
Cc:
AdminCc:

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



Subject: Net::SSH::Perl 2.09.01 does not include Net::SSH::Perl::Util::SSH2MP anymore
Date: Wed, 5 Apr 2017 07:25:42 +0000
To: "bug-Net-SSH-Perl [...] rt.cpan.org" <bug-Net-SSH-Perl [...] rt.cpan.org>
From: "Koszorus, Adrian (Nokia - RO/Timisoara)" <adrian.koszorus [...] nokia.com>
Hello, I have noticed that Net::SSH::perl 2.09.01 doesn't deliver Net::SSH::Perl::Util::SSH2MP anymore. Why? Net::SFTP::Buffer still calls bin2mp ... Undefined subroutine &Net::SFTP::Buffer::bin2mp called at /opt/perl_32/lib/site_perl/5.8.8/Net/SFTP/Buffer.pm line 19. I do have Perl scripts that are using this ... It will cost me a lot to change this now and I can't afford ... And I need Net::SSH::Perl 2.09 ... Thank you for an answer. Regards, Adrian K.
I don't know by myself, but let me ask around... Kind regards, Steffen On Thu Apr 06 00:55:53 2017, adrian.koszorus@nokia.com wrote: Show quoted text
> Hello, > I have noticed that Net::SSH::perl 2.09.01 doesn't deliver > Net::SSH::Perl::Util::SSH2MP anymore. > Why? > Net::SFTP::Buffer still calls bin2mp ... > > Undefined subroutine &Net::SFTP::Buffer::bin2mp called at > /opt/perl_32/lib/site_perl/5.8.8/Net/SFTP/Buffer.pm line 19. > > I do have Perl scripts that are using this ... It will cost me a lot > to change this now and I can't afford ... > And I need Net::SSH::Perl 2.09 ... > > Thank you for an answer. > Regards, > Adrian K.
-- Steffen Schwigon <ss5@renormalist.net> Dresden Perl Mongers <http://dresden-pm.org/>
Lance Kinley, the author of the 2.x features, just sent me a patched Buffer.pm which should make Net::SFTP work again as it depended on Net::SSH::Perl using Math::Pari which in turn is no longer necessary for Net::SSH::Perl. So if you actually need Net::SFTP to work again, then please try if the attached "Buffer.pm" solves your problem. In the meantime, Lance tries to send the fix to Net::SFTP... Kind regards, Steffen On Tue Apr 18 11:50:03 2017, SCHWIGON wrote: Show quoted text
> I don't know by myself, but let me ask around... > > Kind regards, > Steffen > > On Thu Apr 06 00:55:53 2017, adrian.koszorus@nokia.com wrote:
> > Hello, > > I have noticed that Net::SSH::perl 2.09.01 doesn't deliver > > Net::SSH::Perl::Util::SSH2MP anymore. > > Why? > > Net::SFTP::Buffer still calls bin2mp ... > > > > Undefined subroutine &Net::SFTP::Buffer::bin2mp called at > > /opt/perl_32/lib/site_perl/5.8.8/Net/SFTP/Buffer.pm line 19. > > > > I do have Perl scripts that are using this ... It will cost me a lot > > to change this now and I can't afford ... > > And I need Net::SSH::Perl 2.09 ... > > > > Thank you for an answer. > > Regards, > > Adrian K.
>
-- Steffen Schwigon <ss5@renormalist.net> Dresden Perl Mongers <http://dresden-pm.org/>
Subject: Buffer.pm
# $Id: Buffer.pm,v 1.12 2005/01/16 21:36:56 dbrobins Exp $ package Net::SFTP::Buffer; use strict; use Net::SSH::Perl::Buffer; use base qw( Net::SSH::Perl::Buffer ); use Math::Pari qw ( PARI pari2num ); sub new { return shift->SUPER::new(@_, MP => 'SSH2'); } sub get_int64 { my $buf = shift; my $off = defined $_[0] ? shift : $buf->{offset}; $buf->{offset} += 8; bin2mp( $buf->bytes($off, 8) ); } sub put_int64 { my $buf = shift; $buf->{buf} .= mp2bin($_[0], 8); } sub get_attributes { my $buf = shift; Net::SFTP::Attributes->new(Buffer => $buf); } sub put_attributes { my $buf = shift; $buf->{buf} .= $_[0]->as_buffer->bytes; } sub bin2mp { my $s = shift; my $p = PARI(0); my $base = PARI(256); for my $b (split //, $s) { $p = $p * $base + ord $b; } $p; } sub mp2bin { my($p, $l) = @_; $l ||= 0; my $base = PARI(256); my $res = ''; { my $r = $p % $base; my $d = PARI($p-$r) / $base; $res = chr($r) . $res; if ($d >= $base) { $p = $d; redo; } elsif ($d != 0) { $res = chr($d) . $res; } } $res = "\0" x ($l-length($res)) . $res if length($res) < $l; $res; } 1; __END__ =head1 NAME Net::SFTP::Buffer - Read/write buffer class =head1 SYNOPSIS use Net::SFTP::Buffer; my $buffer = Net::SFTP::Buffer->new; =head1 DESCRIPTION I<Net::SFTP::Buffer> inherits from I<Net::SSH::Perl::Buffer> to provide read/write buffer functionality for SSH. SFTP buffers are exactly the same as SSH buffers, with a couple of additions: =over 4 =item * 64-bit integers SFTP requires the use of 64-bit integers to represent very large file sizes. In I<Net::SFTP::Buffer> 64-bit integers are implemented as I<Math::Pari> objects. =item * File attribute bundles Attribute bundles are not strictly a simple data type--they are, in fact, made up of smaller pieces, like 32-bit integers, 64-bit integers, etc.--but for matters of convenience, it is easiest to provide methods to directly serialize/deserialize attributes from buffers. =back =head1 USAGE Usage of I<Net::SFTP::Buffer> objects is exactly the same as usage of I<Net::SSH::Perl::Buffer> objects, with additions of the following methods to support the above data types. =head2 $buffer->get_int64 Extracts a 64-bit integer from I<$buffer> and returns it as a I<Math::Pari> object. =head2 $buffer->put_int64($int) Serializes a 64-bit integer I<$int> into the buffer I<$buffer>; I<$int> can be either a I<Math::Pari> object or a built-in Perl integer, if it is small enough to fit into a Perl int. =head2 $buffer->get_attributes Uses I<Net::SFTP::Attributes> to extract a list of file attributes from I<$buffer>, and returns a I<Net::SFTP::Attributes> object containing those file attributes. =head2 $buffer->put_attributes($attrs) Serializes a I<Net::SFTP::Attributes> object I<$attrs> into the buffer I<$buffer>. =head1 AUTHOR & COPYRIGHTS Please see the Net::SFTP manpage for author, copyright, and license information. =cut
Subject: RE: [rt.cpan.org #120988] Net::SSH::Perl 2.09.01 does not include Net::SSH::Perl::Util::SSH2MP anymore
Date: Wed, 19 Apr 2017 08:26:27 +0000
To: "bug-Net-SSH-Perl [...] rt.cpan.org" <bug-Net-SSH-Perl [...] rt.cpan.org>
From: "Koszorus, Adrian (Nokia - RO/Timisoara)" <adrian.koszorus [...] nokia.com>
Hello, Thank you. I will try it as soon as I can. Regards, Adrian Show quoted text
> -----Original Message----- > From: Steffen Schwigon via RT [mailto:bug-Net-SSH-Perl@rt.cpan.org] > Sent: miercuri, 19 aprilie 2017 11:21 > To: Koszorus, Adrian (Nokia - RO/Timisoara) <adrian.koszorus@nokia.com> > Subject: [rt.cpan.org #120988] Net::SSH::Perl 2.09.01 does not include > Net::SSH::Perl::Util::SSH2MP anymore > > <URL: https://rt.cpan.org/Ticket/Display.html?id=120988 > > > Lance Kinley, the author of the 2.x features, just sent me a patched Buffer.pm > which should make Net::SFTP work again as it depended on Net::SSH::Perl using > Math::Pari which in turn is no longer necessary for Net::SSH::Perl. > > So if you actually need Net::SFTP to work again, then please try if the attached > "Buffer.pm" solves your problem. > In the meantime, Lance tries to send the fix to Net::SFTP... > > Kind regards, > Steffen > > > On Tue Apr 18 11:50:03 2017, SCHWIGON wrote:
> > I don't know by myself, but let me ask around... > > > > Kind regards, > > Steffen > > > > On Thu Apr 06 00:55:53 2017, adrian.koszorus@nokia.com wrote:
> > > Hello, > > > I have noticed that Net::SSH::perl 2.09.01 doesn't deliver > > > Net::SSH::Perl::Util::SSH2MP anymore. > > > Why? > > > Net::SFTP::Buffer still calls bin2mp ... > > > > > > Undefined subroutine &Net::SFTP::Buffer::bin2mp called at > > > /opt/perl_32/lib/site_perl/5.8.8/Net/SFTP/Buffer.pm line 19. > > > > > > I do have Perl scripts that are using this ... It will cost me a lot > > > to change this now and I can't afford ... > > > And I need Net::SSH::Perl 2.09 ... > > > > > > Thank you for an answer. > > > Regards, > > > Adrian K.
> >
> > > -- > Steffen Schwigon <ss5@renormalist.net> > Dresden Perl Mongers <http://dresden-pm.org/>
This patch appears to have fixed the issue for us as well. Any chance this could be released onto CPAN ASAP?
On Thu May 18 14:46:50 2017, DEFCON wrote: Show quoted text
> This patch appears to have fixed the issue for us as well. Any chance > this could be released onto CPAN ASAP?
There is a chance, yes, I just have to do it. I try to get a round tuit this week. Steffen -- Steffen Schwigon <ss5@renormalist.net> Dresden Perl Mongers <http://dresden-pm.org/>
Hi, v2.12 is on its way to CPAN. I hope this fixes the issue officially. Kind regards, Steffen On Tue May 23 09:38:12 2017, SCHWIGON wrote: Show quoted text
> On Thu May 18 14:46:50 2017, DEFCON wrote:
> > This patch appears to have fixed the issue for us as well. Any > > chance > > this could be released onto CPAN ASAP?
> > There is a chance, yes, I just have to do it. I try to get a round > tuit this week. > > Steffen
-- Steffen Schwigon <ss5@renormalist.net> Dresden Perl Mongers <http://dresden-pm.org/>
Subject: [rt.cpan.org #120988]
Date: Tue, 20 Jun 2017 12:02:41 +0200 (CEST)
To: bug-Net-SSH-Perl [...] rt.cpan.org
From: "Benjamin Drieu" <Benjamin.Drieu [...] alcove.fr>
The 2.12 version of Net::SSH::Perl still hqs this issue. Maybe you meant a (coming) 2.13 version as at the time of your latest update to this ticket, the 2.12 was already published?
v2.14 is on its way to CPAN. Sorry for the delay. Does it resolve the trouble? Steffen -- Steffen Schwigon <ss5@renormalist.net> Dresden Perl Mongers <http://dresden-pm.org/>
Subject: RE: [rt.cpan.org #120988] Net::SSH::Perl 2.09.01 does not include Net::SSH::Perl::Util::SSH2MP anymore
Date: Fri, 25 Aug 2017 06:42:27 +0000
To: "bug-Net-SSH-Perl [...] rt.cpan.org" <bug-Net-SSH-Perl [...] rt.cpan.org>
From: "Koszorus, Adrian (Nokia - RO/Timisoara)" <adrian.koszorus [...] nokia.com>
Hello Steffen I have been assigned new tasks and I cannot test this in the near future ... Regards, Adrian Show quoted text
-----Original Message----- From: Steffen Schwigon via RT [mailto:bug-Net-SSH-Perl@rt.cpan.org] Sent: joi, 24 august 2017 09:33 To: Koszorus, Adrian (Nokia - RO/Timisoara) <adrian.koszorus@nokia.com> Subject: [rt.cpan.org #120988] Net::SSH::Perl 2.09.01 does not include Net::SSH::Perl::Util::SSH2MP anymore <URL: https://rt.cpan.org/Ticket/Display.html?id=120988 > v2.14 is on its way to CPAN. Sorry for the delay. Does it resolve the trouble? Steffen -- Steffen Schwigon <ss5@renormalist.net> Dresden Perl Mongers <http://dresden-pm.org/>
I'm quite sure this problem was fixed, in particular the cooperation with SFTP. If I hereby incorrectly closed it, please forgive me and simply re-open it again. Kind regards, Steffen -- Steffen Schwigon <ss5@renormalist.net> Dresden Perl Mongers <http://dresden-pm.org/>
Subject: RE: [rt.cpan.org #120988] Net::SSH::Perl 2.09.01 does not include Net::SSH::Perl::Util::SSH2MP anymore
Date: Fri, 25 Aug 2017 06:42:27 +0000
To: "bug-Net-SSH-Perl [...] rt.cpan.org" <bug-Net-SSH-Perl [...] rt.cpan.org>
From: "Koszorus, Adrian (Nokia - RO/Timisoara)" <adrian.koszorus [...] nokia.com>
Hello Steffen I have been assigned new tasks and I cannot test this in the near future ... Regards, Adrian Show quoted text
-----Original Message----- From: Steffen Schwigon via RT [mailto:bug-Net-SSH-Perl@rt.cpan.org] Sent: joi, 24 august 2017 09:33 To: Koszorus, Adrian (Nokia - RO/Timisoara) <adrian.koszorus@nokia.com> Subject: [rt.cpan.org #120988] Net::SSH::Perl 2.09.01 does not include Net::SSH::Perl::Util::SSH2MP anymore <URL: https://rt.cpan.org/Ticket/Display.html?id=120988 > v2.14 is on its way to CPAN. Sorry for the delay. Does it resolve the trouble? Steffen -- Steffen Schwigon <ss5@renormalist.net> Dresden Perl Mongers <http://dresden-pm.org/>