[Ssh-sftp-perl-users] SSH Web page not working
Brought to you by:
dbrobins
From: Srinivasan V. <sri...@ya...> - 2006-03-25 22:24:55
|
Hello, Following program works fine through command line, same code is not working through Web PAGE...Please see whats wrong.... #!/usr/bin/perl -s use Net::SSH::Perl; print <<"EOF"; Content-type: text/html <HTML><BODY> EOF my $ssh = Net::SSH::Perl->new("hostname", protocol=>'2', debug=>"true"); # $ssh = Net::SSH::Perl->new("hostname"); print "after init"; my ($stdout, $stderr, $exit) = $ssh->login("username","password","true"); print ("$stdout\n"); print ("$stderr\n"); print ("$exit\n"); print "after login"; print $ssh->cmd('ls -l'); print "completed"; print <<"EOF"; </BODY> </HTML> EOF __________________________________________________ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com |