aboutsummaryrefslogtreecommitdiff
path: root/src/http/modules/perl/ngx_http_perl_module.h
Commit message (Collapse)AuthorAge
* Perl: expect escaped URIs in $r->internal_redirect().Maxim Dounin2019-07-12
| | | | | | Similarly to the change in 5491:74bfa803a5aa (1.5.9), we should accept properly escaped URIs and unescape them as needed, else it is not possible to handle URIs with question marks.
* Perl: avoid returning 500 if header was already sent.Maxim Dounin2019-07-12
| | | | | | | Returning NGX_HTTP_INTERNAL_SERVER_ERROR if a perl code died after sending header will lead to a "header already sent" alert. To avoid it, we now check if header was already sent, and return NGX_ERROR instead if it was.
* Perl: disabled unrelated calls from variable handlers.Maxim Dounin2019-07-12
| | | | | | Variable handlers are not expected to send anything to the client, cannot sleep or read body, and are not expected to modify the request. Added appropriate protection to prevent accidental foot shooting.
* Perl: propagate errors.Maxim Dounin2019-07-12
| | | | | | | | | | | | | | | | | | When an error happens, the ctx->error bit is now set, and croak() is called to terminate further processing. The ctx->error bit is checked in ngx_http_perl_call_handler() to cancel further processing, and is also checked in various output functions - to make sure these won't be called if croak() was handled by an eval{} in perl code. In particular, this ensures that output chain won't be called after errors, as filters might not expect this to happen. This fixes some segmentation faults under low memory conditions. Also this stops request processing after filter finalization or request body reading errors. For cases where an HTTP error status can be additionally returned (for example, 416 (Requested Range Not Satisfiable) from the range filter), the ctx->status field is also added.
* Perl: reworked perl module to pass ctx instead of request.Maxim Dounin2019-07-12
| | | | | | | | | | | | | | | | | | | | | | This ensures that correct ctx is always available, including after filter finalization. In particular, this fixes a segmentation fault with the following configuration: location / { image_filter test; perl 'sub { my $r = shift; $r->send_http_header(); $r->print("foo\n"); $r->print("bar\n"); }'; } This also seems to be the only way to correctly handle filter finalization in various complex cases, for example, when embedded perl is used both in the original handler and in an error page called after filter finalization.
* Copyright updated.Maxim Konovalov2012-01-18
|
* optimize $r->sleepIgor Sysoev2008-02-16
|
* $r->variable() supports perl only variablesIgor Sysoev2006-12-12
|
* $r->sleep()Igor Sysoev2006-12-12
|
* Axe several perl interpreter instances: they may be useful in currentlyIgor Sysoev2006-11-26
| | | | | | | unsupported threaded environment, but now they complicate code: *) perl_clone() requires at least duplicating nginx stash; *) the multiplicity requires to re-evalute all precompiled subroutines and nginx stash in new interpreter context.
* style fixIgor Sysoev2006-11-25
|
* check nginx.pm versionIgor Sysoev2006-10-12
|
* nginx-0.4.0-RELEASE importrelease-0.4.0Igor Sysoev2006-08-30
| | | | | | | | | | | | | | | | | | | | *) Change in internal API: the HTTP modules initialization was moved from the init module phase to the HTTP postconfiguration phase. *) Change: now the request body is not read beforehand for the ngx_http_perl_module: it's required to start the reading using the $r->has_request_body method. *) Feature: the ngx_http_perl_module supports the DECLINED return code. *) Feature: the ngx_http_dav_module supports the incoming "Date" header line for the PUT method. *) Feature: the "ssi" directive is available inside the "if" block. *) Bugfix: a segmentation fault occurred if there was an "index" directive with variables and the first index name was without variables; the bug had appeared in 0.1.29.
* nginx-0.3.38-RELEASE importrelease-0.3.38Igor Sysoev2006-04-14
| | | | | | | | | | | | | | | | | | | | | | | | *) Feature: the ngx_http_dav_module. *) Change: the ngx_http_perl_module optimizations. Thanks to Sergey Skvortsov. *) Feature: the ngx_http_perl_module supports the $r->request_body_file method. *) Feature: the "client_body_in_file_only" directive. *) Workaround: now on disk overflow nginx tries to write access logs once a second only. Thanks to Anton Yuzhaninov and Maxim Dounin. *) Bugfix: now the "limit_rate" directive more precisely limits rate if rate is more than 100 Kbyte/s. Thanks to ForJest. *) Bugfix: now the IMAP/POP3 proxy escapes the "\r" and "\n" symbols in login and password to pass authorization server. Thanks to Maxim Dounin.
* nginx-0.3.30-RELEASE importrelease-0.3.30Igor Sysoev2006-02-22
| | | | | | | | | | | *) Change: the ECONNABORTED error log level was changed to "error" from "crit". *) Bugfix: the ngx_http_perl_module could not be build without the ngx_http_ssi_filter_module. *) Bugfix: nginx could not be built on i386 platform, if the PIC was used; the bug had appeared in 0.3.27.
* nginx-0.3.21-RELEASE importrelease-0.3.21Igor Sysoev2006-01-16
*) Feature: the ngx_http_perl_module. *) Change: the "valid_referers" directive allows the referreres without URI part.