Commit fea1b172 authored by gregor herrmann's avatar gregor herrmann

New upstream version 0.77

parent 38a5b70c
Revision history for Perl extension Net::OpenSSH.
0.77 Feb 15, 2018
- Fix regression broking password authentication (bug report
by Russell Shingleton).
0.76 Feb 8, 2018
- Allow passing "file_from" and "from0" options into "rsync"
(bug report and patch by Slaven Rezic, fixes #rt124357)
- Document how to manipulate port forwardings.
- Rename sample directory to examples (fixes #rt122042
reported by Karen Etheridge).
0.75_02 Jul 18, 2017
- Add support for "master_pty_force" and "get_master_pty_log"
features.
- Add support for "subsystem" feature.
0.75_01 Mar 3, 2017
- Use an opaque digest as the last part of the multiplexing
socket path in order to reduce its size (bug report by
Sombrerero_Loco at PerlMonks).
- Improve ctl_path/ctl_dir handling catching more errors
earlier.
- Add support for stdin_keep_open feature (bug report by
fwalters at PerlMonks).
0.74 Feb 10, 2017
- Update list of options accepted by method "sftp" (bug report
by Mirror).
......
......@@ -25,17 +25,17 @@ t/test_user_key.pub
t/known_hosts
t/quoting.t
t/uri.t
sample/expect.pl
sample/change_passwd.pl
sample/autosudo.pl
sample/net-telnet.pl
sample/login_handler.pl
sample/mod_perl_openssh.pm
sample/keep_in_sync.pl
sample/password_from_data.pl
sample/git_ssh_through_mux.pl
sample/git_with_password.pl
sample/sshfs_mount.pl
examples/expect.pl
examples/change_passwd.pl
examples/autosudo.pl
examples/net-telnet.pl
examples/login_handler.pl
examples/mod_perl_openssh.pm
examples/keep_in_sync.pl
examples/password_from_data.pl
examples/git_ssh_through_mux.pl
examples/git_with_password.pl
examples/sshfs_mount.pl
patches/openssh-fwd-stdio-to-streamlocal-1.patch
META.yml Module YAML meta-data (added by MakeMaker)
META.json Module JSON meta-data (added by MakeMaker)
......@@ -4,7 +4,7 @@
"Salvador Fandino <sfandino@yahoo.com>"
],
"dynamic_config" : 1,
"generated_by" : "ExtUtils::MakeMaker version 7.0401, CPAN::Meta::Converter version 2.150005",
"generated_by" : "ExtUtils::MakeMaker version 7.24, CPAN::Meta::Converter version 2.150010",
"license" : [
"perl_5"
],
......@@ -42,6 +42,6 @@
"url" : "https://github.com/salva/p5-Net-OpenSSH"
}
},
"version" : "0.74",
"x_serialization_backend" : "JSON::PP version 2.27400"
"version" : "0.77",
"x_serialization_backend" : "JSON::PP version 2.27400_02"
}
......@@ -7,7 +7,7 @@ build_requires:
configure_requires:
ExtUtils::MakeMaker: '0'
dynamic_config: 1
generated_by: 'ExtUtils::MakeMaker version 7.0401, CPAN::Meta::Converter version 2.150005'
generated_by: 'ExtUtils::MakeMaker version 7.24, CPAN::Meta::Converter version 2.150010'
license: perl
meta-spec:
url: http://module-build.sourceforge.net/META-spec-v1.4.html
......@@ -21,5 +21,5 @@ requires:
Test::More: '0'
resources:
repository: https://github.com/salva/p5-Net-OpenSSH
version: '0.74'
version: '0.77'
x_serialization_backend: 'CPAN::Meta::YAML version 0.018'
......@@ -26,7 +26,7 @@ This module requires these other modules and libraries:
COPYRIGHT AND LICENCE
Copyright (C) 2008-2017 by Salvador Fandino
Copyright (C) 2008-2018 by Salvador Fandino
This library is free software; you can redistribute it and/or modify
it under the same terms as Perl itself, either Perl version 5.10.0 or,
......
This diff is collapsed.
......@@ -70,7 +70,8 @@ my %ctor_opts = (host => 'localhost',
timeout => $timeout,
strict_mode => 0,
batch_mode => ($bg ? 1 : 0),
master_opts => [-o => "StrictHostKeyChecking no"]);
master_opts => [-o => "StrictHostKeyChecking no",
-o => "UserKnownHostsFile /dev/null"]);
my $ssh = Net::OpenSSH->new(%ctor_opts);
......@@ -111,7 +112,7 @@ if (0 and $ssh->error and $num > 4.7) {
plan skip_all => 'Unable to establish SSH connection to localhost!'
if $ssh->error;
plan tests => 46;
plan tests => 48;
sub shell_quote {
my $txt = shift;
......@@ -119,6 +120,8 @@ sub shell_quote {
$txt
}
my $old_open_fds = count_open_fds;
my $muxs = $ssh->get_ctl_path;
ok(-S $muxs, "mux socket exists");
......@@ -195,6 +198,7 @@ my $fh = $ssh->pipe_out("$CAT $sq_cwd/test.dat");
ok($fh, "pipe_out");
$output = join('', <$fh>);
is($output, $lines, "pipe_out lines");
ok(close $fh, "close pipe_out");
my $string = q(#@$#$%&(@#_)erkljgfd'' 345345' { { / // ///foo bar////doz '''' heloo);
......@@ -247,6 +251,14 @@ my $pipe_out = readpipe $rcmd;
chomp $pipe_out;
is ($pipe_out, 'hello', 'make_remote_command');
SKIP: {
skip "Don't know how to count open file descriptors under $^O, patches welcome!", 1
unless defined $old_open_fds;
is(count_open_fds, $old_open_fds, "fds are not leaked")
or diag dump_open_fds;
}
eval {
my $ssh3 = $ssh;
undef $ssh;
......
......@@ -70,4 +70,25 @@ sub shell_is_clean {
1
}
my @last_open_fds;
sub count_open_fds {
@last_open_fds = ();
if ($^O eq 'linux') {
if (opendir my $dh, "/proc/$$/fd") {
my $count = 0;
while (defined(my $fd = readdir $dh)) {
push @last_open_fds, $fd if $fd =~ /^\d+$/;
}
return scalar @last_open_fds;
}
}
()
}
sub dump_open_fds {
my @ls = map { `ls -l /proc/$$/fd/$_ 2>&1` } @last_open_fds;
join('', "Currently open flle descriptors:\n", @ls);
}
1;
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment