Leser: 15
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18
sub connectToServer { my %inConfigParameter = @_; my %configParameter; %configParameter = ( 'host' => $inConfigParameter{target}, 'port' => $inConfigParameter{port} ? $inConfigParameter{port} : 22, 'user' => $inConfigParameter{user}, 'passphrase' => $inConfigParameter{passphrase} ? $inConfigParameter{passphrase} : undef, 'password' => $inConfigParameter{password} ? $inConfigParameter{password} : undef, # 'more' => $inConfigParameter{key} ? [ -i => $inConfigParameter{key} ] : undef, ); #print Dumper(%configParameter); my $sftp = Net::SFTP::Foreign->new(%configParameter); print "GUGUS!!\n"; $sftp->error and die "SSH connection failed: " . $sftp->error; }
1
2
3
4
5
6
7
Net::SFTP::Foreign::Common::_set_error(/home/u24437/scripting/lib/Net/SFTP/Foreign/Common.pm:63):
63: return $sftp->{_error} = dualvar $code, $str;
...
Net::SFTP::Foreign::disconnect(/home/u24437/scripting/lib/Net/SFTP/Foreign.pm:286):
286: }
XML::Parser::Style::Subs::End(/usr/perl5/site_perl/5.8.4/sun4-solaris-64int/XML/Parser/Style/Subs.pm:15):
15: my $expat = shift;
'passphrase' => $inConfigParameter{passphrase} ? $inConfigParameter{passphrase} : undef,