Server IP : 103.119.228.120 / Your IP : 3.16.76.102 Web Server : Apache System : Linux v8.techscape8.com 3.10.0-1160.119.1.el7.tuxcare.els2.x86_64 #1 SMP Mon Jul 15 12:09:18 UTC 2024 x86_64 User : nobody ( 99) PHP Version : 5.6.40 Disable Function : shell_exec,symlink,system,exec,proc_get_status,proc_nice,proc_terminate,define_syslog_variables,syslog,openlog,closelog,escapeshellcmd,passthru,ocinum cols,ini_alter,leak,listen,chgrp,apache_note,apache_setenv,debugger_on,debugger_off,ftp_exec,dl,dll,myshellexec,proc_open,socket_bind,proc_close,escapeshellarg,parse_ini_filepopen,fpassthru,exec,passthru,escapeshellarg,escapeshellcmd,proc_close,proc_open,ini_alter,popen,show_source,proc_nice,proc_terminate,proc_get_status,proc_close,pfsockopen,leak,apache_child_terminate,posix_kill,posix_mkfifo,posix_setpgid,posix_setsid,posix_setuid,dl,symlink,shell_exec,system,dl,passthru,escapeshellarg,escapeshellcmd,myshellexec,c99_buff_prepare,c99_sess_put,fpassthru,getdisfunc,fx29exec,fx29exec2,is_windows,disp_freespace,fx29sh_getupdate,fx29_buff_prepare,fx29_sess_put,fx29shexit,fx29fsearch,fx29ftpbrutecheck,fx29sh_tools,fx29sh_about,milw0rm,imagez,sh_name,myshellexec,checkproxyhost,dosyayicek,c99_buff_prepare,c99_sess_put,c99getsource,c99sh_getupdate,c99fsearch,c99shexit,view_perms,posix_getpwuid,posix_getgrgid,posix_kill,parse_perms,parsesort,view_perms_color,set_encoder_input,ls_setcheckboxall,ls_reverse_all,rsg_read,rsg_glob,selfURL,dispsecinfo,unix2DosTime,addFile,system,get_users,view_size,DirFiles,DirFilesWide,DirPrintHTMLHeaders,GetFilesTotal,GetTitles,GetTimeTotal,GetMatchesCount,GetFileMatchesCount,GetResultFiles,fs_copy_dir,fs_copy_obj,fs_move_dir,fs_move_obj,fs_rmdir,SearchText,getmicrotime MySQL : ON | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : ON | Pkexec : ON Directory : /usr/local/ssl/local/ssl/local/ssl/local/ssl/local/ssl/local/share/man/man3/ |
Upload File : |
.\" Automatically generated by Pod::Man 2.27 (Pod::Simple 3.28) .\" .\" Standard preamble: .\" ======================================================================== .de Sp \" Vertical space (when we can't use .PP) .if t .sp .5v .if n .sp .. .de Vb \" Begin verbatim text .ft CW .nf .ne \\$1 .. .de Ve \" End verbatim text .ft R .fi .. .\" Set up some character translations and predefined strings. \*(-- will .\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left .\" double quote, and \*(R" will give a right double quote. \*(C+ will .\" give a nicer C++. Capital omega is used to do unbreakable dashes and .\" therefore won't be available. \*(C` and \*(C' expand to `' in nroff, .\" nothing in troff, for use with C<>. .tr \(*W- .ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p' .ie n \{\ . ds -- \(*W- . ds PI pi . if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch . if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch . ds L" "" . ds R" "" . ds C` "" . ds C' "" 'br\} .el\{\ . ds -- \|\(em\| . ds PI \(*p . ds L" `` . ds R" '' . ds C` . ds C' 'br\} .\" .\" Escape single quotes in literal strings from groff's Unicode transform. .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" .\" If the F register is turned on, we'll generate index entries on stderr for .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index .\" entries marked with X<> in POD. Of course, you'll have to process the .\" output yourself in some meaningful fashion. .\" .\" Avoid warning from groff about undefined register 'F'. .de IX .. .nr rF 0 .if \n(.g .if rF .nr rF 1 .if (\n(rF:(\n(.g==0)) \{ . if \nF \{ . de IX . tm Index:\\$1\t\\n%\t"\\$2" .. . if !\nF==2 \{ . nr % 0 . nr F 2 . \} . \} .\} .rr rF .\" .\" Accent mark definitions (@(#)ms.acc 1.5 88/02/08 SMI; from UCB 4.2). .\" Fear. Run. Save yourself. No user-serviceable parts. . \" fudge factors for nroff and troff .if n \{\ . ds #H 0 . ds #V .8m . ds #F .3m . ds #[ \f1 . ds #] \fP .\} .if t \{\ . ds #H ((1u-(\\\\n(.fu%2u))*.13m) . ds #V .6m . ds #F 0 . ds #[ \& . ds #] \& .\} . \" simple accents for nroff and troff .if n \{\ . ds ' \& . ds ` \& . ds ^ \& . ds , \& . ds ~ ~ . ds / .\} .if t \{\ . ds ' \\k:\h'-(\\n(.wu*8/10-\*(#H)'\'\h"|\\n:u" . ds ` \\k:\h'-(\\n(.wu*8/10-\*(#H)'\`\h'|\\n:u' . ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'^\h'|\\n:u' . ds , \\k:\h'-(\\n(.wu*8/10)',\h'|\\n:u' . ds ~ \\k:\h'-(\\n(.wu-\*(#H-.1m)'~\h'|\\n:u' . ds / \\k:\h'-(\\n(.wu*8/10-\*(#H)'\z\(sl\h'|\\n:u' .\} . \" troff and (daisy-wheel) nroff accents .ds : \\k:\h'-(\\n(.wu*8/10-\*(#H+.1m+\*(#F)'\v'-\*(#V'\z.\h'.2m+\*(#F'.\h'|\\n:u'\v'\*(#V' .ds 8 \h'\*(#H'\(*b\h'-\*(#H' .ds o \\k:\h'-(\\n(.wu+\w'\(de'u-\*(#H)/2u'\v'-.3n'\*(#[\z\(de\v'.3n'\h'|\\n:u'\*(#] .ds d- \h'\*(#H'\(pd\h'-\w'~'u'\v'-.25m'\f2\(hy\fP\v'.25m'\h'-\*(#H' .ds D- D\\k:\h'-\w'D'u'\v'-.11m'\z\(hy\v'.11m'\h'|\\n:u' .ds th \*(#[\v'.3m'\s+1I\s-1\v'-.3m'\h'-(\w'I'u*2/3)'\s-1o\s+1\*(#] .ds Th \*(#[\s+2I\s-2\h'-\w'I'u*3/5'\v'-.3m'o\v'.3m'\*(#] .ds ae a\h'-(\w'a'u*4/10)'e .ds Ae A\h'-(\w'A'u*4/10)'E . \" corrections for vroff .if v .ds ~ \\k:\h'-(\\n(.wu*9/10-\*(#H)'\s-2\u~\d\s+2\h'|\\n:u' .if v .ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'\v'-.4m'^\v'.4m'\h'|\\n:u' . \" for low resolution devices (crt and lpr) .if \n(.H>23 .if \n(.V>19 \ \{\ . ds : e . ds 8 ss . ds o a . ds d- d\h'-1'\(ga . ds D- D\h'-1'\(hy . ds th \o'bp' . ds Th \o'LP' . ds ae ae . ds Ae AE .\} .rm #[ #] #H #V #F C .\" ======================================================================== .\" .IX Title "Net::Server::HTTP 3" .TH Net::Server::HTTP 3 "2014-05-06" "perl v5.16.3" "User Contributed Perl Documentation" .\" For nroff, turn off justification. Always turn off hyphenation; it makes .\" way too many mistakes in technical documents. .if n .ad l .nh .SH "NAME" Net::Server::HTTP \- very basic Net::Server based HTTP server class .SH "TEST ONE LINER" .IX Header "TEST ONE LINER" .Vb 2 \& perl \-e \*(Aquse base qw(Net::Server::HTTP); main\->run(port => 8080)\*(Aq \& # will start up an echo server .Ve .SH "SYNOPSIS" .IX Header "SYNOPSIS" .Vb 2 \& use base qw(Net::Server::HTTP); \& _\|_PACKAGE_\|_\->run; \& \& sub process_http_request { \& my $self = shift; \& \& print "Content\-type: text/html\en\en"; \& print "<form method=post action=/bam><input type=text name=foo><input type=submit></form>\en"; \& \& require Data::Dumper; \& local $Data::Dumper::Sortkeys = 1; \& \& require CGI; \& my $form = {}; \& my $q = CGI\->new; $form\->{$_} = $q\->param($_) for $q\->param; \& \& print "<pre>".Data::Dumper\->Dump([\e%ENV, $form], [\*(Aq*ENV\*(Aq, \*(Aqform\*(Aq])."</pre>"; \& } .Ve .SH "DESCRIPTION" .IX Header "DESCRIPTION" Even though Net::Server::HTTP doesn't fall into the normal parallel of the other Net::Server flavors, handling \s-1HTTP\s0 requests is an often requested feature and is a standard and simple protocol. .PP Net::Server::HTTP begins with base type MultiType defaulting to Net::Server::Fork. It is easy to change it to any of the other Net::Server flavors by passing server_type => \f(CW$other_flavor\fR in the server configurtation. The port has also been defaulted to port 80 \- but could easily be changed to another through the server configuration. You can also very easily add ssl by including, proto=>\*(L"ssl\*(R" and provide a SSL_cert_file and SSL_key_file. .PP For example, here is a basic server that will bind to all interfaces, will speak both \s-1HTTP\s0 on port 8080 as well as \s-1HTTPS\s0 on 8443, and will speak both IPv4, as well as IPv6 if it is available. .PP .Vb 1 \& use base qw(Net::Server::HTTP); \& \& _\|_PACKAGE_\|_\->run( \& port => [8080, "8443/ssl"], \& ipv => \*(Aq*\*(Aq, # IPv6 if available \& SSL_key_file => \*(Aq/my/key\*(Aq, \& SSL_cert_file => \*(Aq/my/cert\*(Aq, \& ); .Ve .SH "METHODS" .IX Header "METHODS" .ie n .IP """_init_access_log""" 4 .el .IP "\f(CW_init_access_log\fR" 4 .IX Item "_init_access_log" Used to open and initialize any requested access_log (see access_log_file and access_log_format). .ie n .IP """_tie_client_stdout""" 4 .el .IP "\f(CW_tie_client_stdout\fR" 4 .IX Item "_tie_client_stdout" Used to initialize automatic response header parsing. .ie n .IP """process_http_request""" 4 .el .IP "\f(CWprocess_http_request\fR" 4 .IX Item "process_http_request" Will be passed the client handle, and will have \s-1STDOUT\s0 and \s-1STDIN\s0 tied to the client. .Sp During this method, the \f(CW%ENV\fR will have been set to a standard \s-1CGI\s0 style environment. You will need to be sure to print the Content-type header. This is one change from the other standard Net::Server base classes. .Sp During this method you can read from \f(CW%ENV\fR and \s-1STDIN\s0 just like a normal \&\s-1HTTP\s0 request in other web servers. You can print to \s-1STDOUT\s0 and Net::Server will handle the header negotiation for you. .Sp Note: Net::Server::HTTP has no concept of document root or script aliases or default handling of static content. That is up to the consumer of Net::Server::HTTP to work out. .Sp Net::Server::HTTP comes with a basic \f(CW%ENV\fR display installed as the default process_http_request method. .ie n .IP """process_request""" 4 .el .IP "\f(CWprocess_request\fR" 4 .IX Item "process_request" This method has been overridden in Net::Server::HTTP \- you should not use it while using Net::Server::HTTP. This overridden method parses the environment and sets up request alarms and handles dying failures. It calls process_http_request once the request is ready and headers have been parsed. .ie n .IP """process_headers""" 4 .el .IP "\f(CWprocess_headers\fR" 4 .IX Item "process_headers" Used to read in the incoming headers and set the \s-1ENV.\s0 .ie n .IP """_init_http_request_info""" 4 .el .IP "\f(CW_init_http_request_info\fR" 4 .IX Item "_init_http_request_info" Called at the end of process_headers. Initializes the contents of http_request_info. .ie n .IP """http_request_info""" 4 .el .IP "\f(CWhttp_request_info\fR" 4 .IX Item "http_request_info" Returns a hashref of information specific to the current request. This information will be used for logging later on. .ie n .IP """send_status""" 4 .el .IP "\f(CWsend_status\fR" 4 .IX Item "send_status" Takes an \s-1HTTP\s0 status and a message. Sends out the correct headers. .ie n .IP """send_500""" 4 .el .IP "\f(CWsend_500\fR" 4 .IX Item "send_500" Calls send_status with 500 and the argument passed to send_500. .IP "c<log_http_request>" 4 .IX Item "c<log_http_request>" Called at the end of post_process_request. The default method looks for the default access_log_format and checks if logging was initilized during _init_access_log. If both of these exist, the http_request_info is formatted using http_log_format and the result is logged. .ie n .IP """http_log_format""" 4 .el .IP "\f(CWhttp_log_format\fR" 4 .IX Item "http_log_format" Takes a format string, and request_info and returns a formatted string. The format should follow the apache mod_log_config specification. As in the mod_log_config specification, backslashes, quotes should be escaped with backslashes and you may also include \en and \et characters as well. .Sp The following is a listing of the available parameters as well as sample output based on a very basic \s-1HTTP\s0 server. .Sp .Vb 10 \& %% % # a percent \& %a ::1 # remote ip \& %A ::1 # local ip \& %b 83 # response size (\- if 0) Common Log Format \& %B 83 # response size \& %{bar}C baz # value of cookie by that name \& %D 916 # elapsed in microseconds \& %{HTTP_COOKIE}e bar=baz # value of %ENV by that name \& %f \- # filename \- unused \& %h ::1 # remote host if lookups are on, remote ip otherwise \& %H http # request protocol \& %{Host}i localhost:8080 # request header by that name \& %I 336 # bytes received including headers \& %l \- # remote logname \- unsused \& %m GET # request method \& %n Just a note # http_note by that name \& %{Content\-type}o text/html # output header by that name \& %O 189 # response size including headers \& %p 8080 # server port \& %P 22999 # pid \- does not support %{tid}P \& q ?hello=there # query_string including ? (\- otherwise) \& r GET /bam?hello=there HTTP/1.1 # the first line of the request \& %s 200 # response status \& %u \- # remote user \- unused \& %U /bam # request path (no query string) \& %t [06/Jun/2012:12:14:21 \-0600] # http_log_time standard format \& %t{%F %T %z}t [2012\-06\-06 12:14:21 \-0600] # http_log_time with format \& %T 0 # elapsed time in seconds \& %v localhost:8080 # http_log_vhost \- partial implementation \& %V localhost:8080 # http_log_vhost \- partial implementation \& %X \- # Connection completed and is \*(Aqclose\*(Aq (\-) .Ve .Sp Additionally, the log parsing allows for the following formats. .Sp .Vb 5 \& %>s 200 # status of last request \& %<s 200 # status of original request \& %400a \- # remote ip if status is 400 \& %!400a ::1 # remote ip if status is not 400 \& %!200a \- # remote ip if status is not 200 .Ve .Sp There are few bits not completely implemented: .Sp .Vb 7 \& > and < # There is no internal redirection \& %I # The answer to this is based on header size and Content\-length \& instead of the more correct actual number of bytes read though \& in common cases those would be the same. \& %X # There is no Connection keepalive in the default server. \& %v and %V # There are no virtual hosts in the default HTTP server. \& %{tid}P # The default servers are not threaded. .Ve .Sp See the \f(CW\*(C`access_log_format\*(C'\fR option for how to set a different format as well as to see the default string. .ie n .IP """exec_cgi""" 4 .el .IP "\f(CWexec_cgi\fR" 4 .IX Item "exec_cgi" Allow for calling an external script as a \s-1CGI. \s0 This will use IPC::Open3 to fork a new process and read/write from it. .Sp .Vb 2 \& use base qw(Net::Server::HTTP); \& _\|_PACKAGE_\|_\->run; \& \& sub process_http_request { \& my $self = shift; \& \& if ($ENV{\*(AqPATH_INFO\*(Aq} && $ENV{\*(AqPATH_INFO\*(Aq} =~ s{^ (/foo) (?= $ | /) }{}x) { \& $ENV{\*(AqSCRIPT_NAME\*(Aq} = $1; \& my $file = "/var/www/cgi\-bin/foo"; # assuming this exists \& return $self\->exec_cgi($file); \& } \& \& print "Content\-type: text/html\en\en"; \& print "<a href=/foo>Foo</a>"; \& } .Ve .Sp At this first release, the parent server is not tracking the child script which may cause issues if the script is running when a \s-1HUP\s0 is received. .ie n .IP """http_log_time""" 4 .el .IP "\f(CWhttp_log_time\fR" 4 .IX Item "http_log_time" Used to implement the \f(CW%t\fR format. .ie n .IP """http_log_env""" 4 .el .IP "\f(CWhttp_log_env\fR" 4 .IX Item "http_log_env" Used to implement the \f(CW%e\fR format. .ie n .IP """http_log_cookie""" 4 .el .IP "\f(CWhttp_log_cookie\fR" 4 .IX Item "http_log_cookie" Used to implement the \f(CW%C\fR format. .ie n .IP """http_log_header_in""" 4 .el .IP "\f(CWhttp_log_header_in\fR" 4 .IX Item "http_log_header_in" used to implement the \f(CW%i\fR format. .ie n .IP """http_log_note""" 4 .el .IP "\f(CWhttp_log_note\fR" 4 .IX Item "http_log_note" Used to implement the \f(CW%n\fR format. .ie n .IP """http_note""" 4 .el .IP "\f(CWhttp_note\fR" 4 .IX Item "http_note" Takes a key and an optional value. If passed a key and value, sets the note for that key. Always returns the value. These notes currently only are used for %{key}n output format. .ie n .IP """http_log_header_out""" 4 .el .IP "\f(CWhttp_log_header_out\fR" 4 .IX Item "http_log_header_out" Used to implement the \f(CW%o\fR format. .ie n .IP """http_log_pid""" 4 .el .IP "\f(CWhttp_log_pid\fR" 4 .IX Item "http_log_pid" Used to implement the \f(CW%P\fR format. .ie n .IP """http_log_vhost""" 4 .el .IP "\f(CWhttp_log_vhost\fR" 4 .IX Item "http_log_vhost" Used to implement the \f(CW%v\fR and \f(CW%V\fR formats. .ie n .IP """http_log_constat""" 4 .el .IP "\f(CWhttp_log_constat\fR" 4 .IX Item "http_log_constat" Used to implement the \f(CW%X\fR format. .ie n .IP """exec_trusted_perl""" 4 .el .IP "\f(CWexec_trusted_perl\fR" 4 .IX Item "exec_trusted_perl" Allow for calling an external perl script. This method will still fork, but instead of using IPC::Open3, it simply requires the perl script. That means that the running script will be able to make use of any shared memory. It also means that the \s-1STDIN/STDOUT/STDERR\s0 handles the script is using are those directly bound by the server process. .Sp .Vb 2 \& use base qw(Net::Server::HTTP); \& _\|_PACKAGE_\|_\->run; \& \& sub process_http_request { \& my $self = shift; \& \& if ($ENV{\*(AqPATH_INFO\*(Aq} && $ENV{\*(AqPATH_INFO\*(Aq} =~ s{^ (/foo) (?= $ | /) }{}x) { \& $ENV{\*(AqSCRIPT_NAME\*(Aq} = $1; \& my $file = "/var/www/cgi\-bin/foo"; # assuming this exists \& return $self\->exec_trusted_perl($file); \& } \& \& print "Content\-type: text/html\en\en"; \& print "<a href=/foo>Foo</a>"; \& } .Ve .Sp At this first release, the parent server is not tracking the child script which may cause issues if the script is running when a \s-1HUP\s0 is received. .ie n .IP """exec_fork_hook""" 4 .el .IP "\f(CWexec_fork_hook\fR" 4 .IX Item "exec_fork_hook" This method is called after the fork of exec_trusted_perl and exec_cgi hooks. It is passed the pid (0 if the child) and the file being ran. Note, that the hook will not be called from the child during exec_cgi. .ie n .IP """http_dispatch""" 4 .el .IP "\f(CWhttp_dispatch\fR" 4 .IX Item "http_dispatch" Called if the default process_http_request and process_request methods have not been overridden and \f(CW\*(C`app\*(C'\fR configuration parameters have been passed. In this case this replaces the default echo server. You can also enable this subsystem for your own direct use by setting enable_dispatch to true during configuration. See the \f(CW\*(C`app\*(C'\fR configuration item. It will be passed a dispatch qr (regular expression) generated during _check_dispatch, and a dispatch table. The qr will be applied to path_info. This mechanism could be used to augment Net::Server::HTTP with document root and virtual host capabilities. .SH "OPTIONS" .IX Header "OPTIONS" In addition to the command line arguments of the Net::Server base classes you can also set the following options. .IP "max_header_size" 4 .IX Item "max_header_size" Defaults to 100_000. Maximum number of bytes to read while parsing headers. .IP "server_revision" 4 .IX Item "server_revision" Defaults to Net::Server::HTTP/$Net::Server::VERSION. .IP "timeout_header" 4 .IX Item "timeout_header" Defaults to 15 \- number of seconds to wait for parsing headers. .IP "timeout_idle" 4 .IX Item "timeout_idle" Defaults to 60 \- number of seconds a request can be idle before the request is closed. .IP "access_log_file" 4 .IX Item "access_log_file" Defaults to undef. If true, this represents the location of where the access log should be written to. If a special value of \s-1STDERR\s0 is passed, the access log entry will be writing to the same location as the \s-1ERROR\s0 log. .IP "access_log_format" 4 .IX Item "access_log_format" Should be a valid apache log format that will be passed to http_log_format. See the http_log_format method for more information. .Sp The default value is the \s-1NCSA\s0 extended/combined log format: .Sp .Vb 1 \& \*(Aq%h %l %u %t \e"%r\e" %>s %b \e"%{Referer}i\e" \e"%{User\-Agent}i\e"\*(Aq .Ve .IP "app" 4 .IX Item "app" Takes one or more items and registers them for dispatch. Arguments may be supplied as an arrayref containing a location/target pairs, a hashref containing a location/target pairs, a bare code ref that will use \*(L"/\*(R" as the location and the codref as the target, a string with a space indicating \*(L"location target\*(R", a string containing \*(L"location=target\*(R", or finally a string that will be used as both location and target. For items passed as an arrayref or hashref, the target may be a coderef which will be called and should handle the request. In all other cases the target should be a valid executable suitable for passing to exec_cgi. .Sp The locations will be added in the order that they are configured. They will be added to a regular expression which will be applied to the incoming \s-1PATH_INFO\s0 string. If the match is successful, the \&\f(CW$ENV\fR{'\s-1SCRIPT_NAME\s0'} will be set to the matched portion and the matched portion will be removed from \f(CW$ENV\fR{'\s-1PATH_INFO\s0'}. .Sp Once an app has been passed, it is necessary for the server to listen on /. Therefore if \*(L"/\*(R" has not been specifically configured for dispatch, the first found dispatch target will also be used to handle \&\*(L"/\*(R". .Sp For convenience, if the log_level is 2 or greater, the dispatch table is output to the log. .Sp This mechanism is left as a generic mechanism suitable for overriding by servers meant to handle more complex dispatch. At the moment there is no handling of virtual hosts. At some point we will add in the default ability to play static content and likely for the ability to configure virtual hosts \- or that may have to wait for a third party module. .Sp .Vb 3 \& app => "/home/paul/foo.cgi", \& # Dispatch: /home/paul/foo.cgi => home/paul/foo.cgi \& # Dispatch: / => home/paul/foo.cgi (default) \& \& \& app => "../../foo.cgi", \& app => "./bar.cgi", \& app => "baz ./bar.cgi", \& app => "bim=./bar.cgi", \& # Dispatch: /foo.cgi => ../../foo.cgi \& # Dispatch: /bar.cgi => ./bar.cgi \& # Dispatch: /baz => ./bar.cgi \& # Dispatch: /bim => ./bar.cgi \& # Dispatch: / => ../../foo.cgi (default) \& \& \& app => "../../foo.cgi", \& app => "/=./bar.cgi", \& # Dispatch: /foo.cgi => ../../foo.cgi \& # Dispatch: / => ./bar.cgi \& \& # you could also do this on the commandline \& net\-server HTTP app ../../foo.cgi app /=./bar.cgi \& \& # extended options when configured from code \& \& Net::Server::HTTP\->run(app => { # loses order of matching \& \*(Aq/\*(Aq => sub { ... }, \& \*(Aq/foo\*(Aq => sub { ... }, \& \*(Aq/bar\*(Aq => \*(Aq/path/to/some.cgi\*(Aq, \& }); \& \& Net::Server::HTTP\->run(app => [ \& \*(Aq/\*(Aq => sub { ... }, \& \*(Aq/foo\*(Aq => sub { ... }, \& \*(Aq/bar\*(Aq => \*(Aq/path/to/some.cgi\*(Aq, \& ]); .Ve .SH "TODO" .IX Header "TODO" Add support for writing out \s-1HTTP/1.1.\s0 .SH "AUTHOR" .IX Header "AUTHOR" Paul T. Seamons paul@seamons.com .SH "THANKS" .IX Header "THANKS" See Net::Server .SH "SEE ALSO" .IX Header "SEE ALSO" Please see also Net::Server::Fork, Net::Server::INET, Net::Server::PreFork, Net::Server::PreForkSimple, Net::Server::MultiType, Net::Server::Single Net::Server::SIG Net::Server::Daemonize Net::Server::Proto