#!/usr/bin/perl -w package NetServer; use strict; use base qw(Net::Server::Fork); sub SSL_key_file { "key.pem" } sub SSL_cert_file { "cert.pem" } sub process_request { my $self = shift; ### COMMAND PIPE print "Executing Command Pipe\n"; open DATA, "/usr/bin/echo ==== Command Pipe Successful|" or die "Couldn't open command: $!"; while (defined(my $line = )) { chomp($line); print "$line\n"; } close DATA; ### SYSTEM COMMAND print "Executing System Command\n"; system("/usr/bin/echo ==== System Command Successful"); ### EXEC COMMAND print "Executing Exec Command\n"; exec "/usr/bin/echo ==== Exec Command Successful" or die "Couldn't exec command: $!"; } #NetServer->run(proto => 'ssl', port=>12345); NetServer->run(proto => 'ssleay', port=>12345);