Subject: | Net::OpenSSH-0.53_04 -- issue with scp *bug fix* |
Date: | Wed, 23 Nov 2011 19:49:03 +0000 |
To: | "bug-Net-OpenSSH [...] rt.cpan.org" <bug-Net-OpenSSH [...] rt.cpan.org> |
From: | "Slezak, Andrew J" <andrew.j.slezak [...] jpmorgan.com> |
Author,
Thank you for this excellent perl module.
When using scp with this module, it passes "-l user" to the scp command.
The scp command expects -l to be a bandwidth limit instead of the username.
usage: scp [-1246BCpqrv] [-c cipher] [-F ssh_config] [-i identity_file]
[-l limit] [-o ssh_option] [-P port] [-S program]
[[user@]host1:]file1 [...] [[user@]host2:]file2
With the changes I've suggested, your module will use the user@host syntax instead of -l user.
my @ssh_opts;
# TODO: are those options really requiered or just do they eat on
# the command line limited length?
#push @ssh_opts, -l => $user if defined $user;
#
#andrew.j.slezak@jpmorgan.com --
#-l option does not work for scp ... change to user@host
#
if (defined $user) {
$host = "$user\@$host";
$host_ssh = "$user\@$host_ssh";
}
If you could update your module it would be most appreciated. This works for me on Redhat 3/4/5 servers.
Thanks & Regards, -Andrew Slezak / JPMorgan
This email is confidential and subject to important disclaimers and
conditions including on offers for the purchase or sale of
securities, accuracy and completeness of information, viruses,
confidentiality, legal privilege, and legal entity disclaimers,
available at http://www.jpmorgan.com/pages/disclosures/email.