Help for this page
use Net::SCP qw(scp); my ($host, $username) = ("example.com", "eric"); ... for my $file (@files) { $scp->put($file) or warn $scp->{errstr}; }
use Net::SSH2; my $ssh2 = Net::SSH2->new(); ... if ($ssh2->auth_keyboard('password')) { for my $file (@files) { scp_put($file); } }