lighttpd1.4/tests
Glenn Strauss 9af58a9716 revert 1.4.40 swap of REQUEST_URI, REDIRECT_URI (fixes #2738)
reverts part of commit:dbdab5db which swapped REQUEST_URI, REDIRECT_URI

x-ref:
  "mediawiki redirect loop if REQUEST_URI not orig req in 1.4.40"
  https://redmine.lighttpd.net/issues/2738

Explanation:

REQUEST_URI and REDIRECT_URI are not part of CGI standard environment.
The reason for their existence is that PATH_INFO in CGI environment may
be different from the path in the current request.  The main reason for
this potential difference is that the URI path is normalized to a path
in the filesystem and tested against the filesystem to determine which
part is SCRIPT_NAME and which part is PATH_INFO.  In case-insensitive
filesystems, the URI might be lowercased before testing against the
filesystem, leading to loss of case-sensitive submission in any
resulting PATH_INFO.  Also, duplicated slashes "///" and directory
references "/." and "/.." are removed, including prior path component in
the case of "/..".  This might be undesirable when the information after
the SCRIPT_NAME is virtual information and there target script needs the
virtual path preserved as-is.  In that case, the target script can
re-parse REQUEST_URI (or REDIRECT_URI, as appropriate) to obtain the
unmodified information from the URI.

con->request.uri is equivalent to con->request.orig_uri unless the
request has been internally rewritten (e.g. by mod_rewrite, mod_magnet,
others), in which case con->request.orig_uri is the request made by the
client, and con->request.uri is the current URI being processed.

Historical REQUEST_URI (environment variable) lighttpd inconsistencies
- mod_cml     set REQUEST_URI to con->request.orig_uri
- mod_cgi     set REQUEST_URI to con->request.orig_uri
- mod_fastcgi set REQUEST_URI to con->request.orig_uri
- mod_scgi    set REQUEST_URI to con->request.orig_uri

- mod_ssi     set            REQUEST_URI to current con->request.uri
- mod_magnet  set MAGNET_ENV_REQUEST_URI to current con->request.uri
              and MAGNET_ENV_REQUEST_ORIG_URI to con->request.orig_uri

Historical REDIRECT_URI (environment variable) previously set only in
mod_fastcgi and mod_scgi, and set to con->request.uri

Since lighttpd 1.4.40 provides REDIRECT_URI with con->request.orig_uri,
changes were made to REQUEST_URI for consistency, with the hope that
there would be little impact to existing configurations since the
request uri and original request uri are the same unless there has been
an internal redirect.  It turns out that various PHP frameworks use
REQUEST_URI and require that it be the original URI requested by client.

Therefore, this change is being reverted, and lighttpd will set
REQUEST_URI to con->request.orig_uri in mod_cgi, mod_fastcgi, mod_scgi
as was done in lighttpd 1.4.39 and earlier.  Similarly, REDIRECT_URI
also has the prior behavior in mod_fastcgi and mod_scgi, and added to
mod_cgi.

A future release of lighttpd might change mod_ssi to be consistent with
the other modules in setting REQUEST_URI to con->request.orig_uri and to
add REDIRECT_URI, when an internal redirect has occurred.
2016-07-23 02:13:41 -04:00
..
docroot revert 1.4.40 swap of REQUEST_URI, REDIRECT_URI (fixes #2738) 2016-07-23 02:13:41 -04:00
404-handler.conf [core] server.error-handler new directive for error pages (fixes #2702) 2016-04-25 01:01:08 -04:00
CMakeLists.txt [cmake] lowercase commands, whitespace cleanup, remove clutter in else(...), endif(...), endforeach(...) 2015-08-22 16:01:02 +00:00
LightyTest.pm [tests] do not half-close socket before having received the response (fixes #2688) 2015-12-04 20:22:38 +00:00
Makefile.am add some until now missing files to dist tarball 2015-06-21 12:47:14 +00:00
SConscript [scons] various improvements 2015-08-29 09:28:04 +00:00
bug-06.conf [tests] search for perl in PATH instead of /usr/bin; whitespace + test config cleanups 2015-08-22 20:51:08 +00:00
bug-12.conf [tests] search for perl in PATH instead of /usr/bin; whitespace + test config cleanups 2015-08-22 20:51:08 +00:00
cachable.t parse If-None-Match for ETag validation (fixes #2578) 2015-07-05 16:59:01 +00:00
cleanup.sh [scons] various improvements 2015-08-29 09:28:04 +00:00
condition.conf [core] never evaluate else branches until the previous branches are aready (fixes #2598) 2016-02-21 17:56:24 +00:00
core-404-handler.t [core] server.error-handler new directive for error pages (fixes #2702) 2016-04-25 01:01:08 -04:00
core-condition.t [core] never evaluate else branches until the previous branches are aready (fixes #2598) 2016-02-21 17:56:24 +00:00
core-keepalive.t - change s/// separator that it doesn't confuse vim 2008-01-15 22:03:59 +00:00
core-request.t fix SQL injection / host name validation (thx Jann Horn) 2014-03-12 12:03:55 +00:00
core-response.t [core] encode path with ENCODING_REL_URI in redirect to directory (fixes #2661, thx gstrauss) 2015-11-07 15:00:18 +00:00
core-var-include.t - change s/// separator that it doesn't confuse vim 2008-01-15 22:03:59 +00:00
core.t - change s/// separator that it doesn't confuse vim 2008-01-15 22:03:59 +00:00
fastcgi-10.conf [tests] search for perl in PATH instead of /usr/bin; whitespace + test config cleanups 2015-08-22 20:51:08 +00:00
fastcgi-13.conf [tests] search for perl in PATH instead of /usr/bin; whitespace + test config cleanups 2015-08-22 20:51:08 +00:00
fastcgi-auth.conf [tests] search for perl in PATH instead of /usr/bin; whitespace + test config cleanups 2015-08-22 20:51:08 +00:00
fastcgi-responder.conf [tests] search for perl in PATH instead of /usr/bin; whitespace + test config cleanups 2015-08-22 20:51:08 +00:00
fcgi-auth.c Fix non-ANSI function declarations. 2012-08-31 14:11:41 +00:00
fcgi-responder.c Fix non-ANSI function declarations. 2012-08-31 14:11:41 +00:00
lighttpd.conf [mod_access] new directive url.access-allow (fixes #1421) 2016-07-13 04:12:08 -04:00
lighttpd.htpasswd [mod_auth] skip blank lines and comment lines (fixes #2327) 2016-04-28 13:13:43 -04:00
lighttpd.user moved everything below trunk/ and added branches/ and tags/ 2005-02-20 14:27:00 +00:00
lowercase.conf [tests] search for perl in PATH instead of /usr/bin; whitespace + test config cleanups 2015-08-22 20:51:08 +00:00
lowercase.t - change s/// separator that it doesn't confuse vim 2008-01-15 22:03:59 +00:00
mod-access.t [mod_access] new directive url.access-allow (fixes #1421) 2016-07-13 04:12:08 -04:00
mod-auth.t [mod_auth] fix Digest auth to be better than Basic (fixes #1844) 2016-07-16 23:25:53 -04:00
mod-cgi.t [mod_cgi] handle local redirect response (fixes #2108) 2016-07-14 16:31:08 -04:00
mod-compress.conf [tests] search for perl in PATH instead of /usr/bin; whitespace + test config cleanups 2015-08-22 20:51:08 +00:00
mod-compress.t mod_compress: match partial+full content-type (fixes #1552) 2009-10-11 19:27:55 +00:00
mod-extforward.conf [tests] search for perl in PATH instead of /usr/bin; whitespace + test config cleanups 2015-08-22 20:51:08 +00:00
mod-extforward.t - support chained proxies in mod_extforward (#1528) 2008-01-21 08:21:20 +00:00
mod-fastcgi.t [cygwin] fix mod_proxy and mod_fastcgi ioctl use 2016-06-23 15:46:44 -04:00
mod-proxy.t [tests] search for perl in PATH instead of /usr/bin; whitespace + test config cleanups 2015-08-22 20:51:08 +00:00
mod-redirect.t - change s/// separator that it doesn't confuse vim 2008-01-15 22:03:59 +00:00
mod-rewrite.t [tests] search for perl in PATH instead of /usr/bin; whitespace + test config cleanups 2015-08-22 20:51:08 +00:00
mod-secdownload.t [mod_secdownload] add required algorithm option; old behaviour available as "md5", new options "hmac-sha1" and "hmac-sha256" 2015-11-22 22:22:22 +00:00
mod-setenv.t - change s/// separator that it doesn't confuse vim 2008-01-15 22:03:59 +00:00
mod-simplevhost.conf [tests] search for perl in PATH instead of /usr/bin; whitespace + test config cleanups 2015-08-22 20:51:08 +00:00
mod-simplevhost.t [tests] add mod_simplevhost tests 2013-08-30 13:15:01 +00:00
mod-ssi.t [mod_ssi] more flexible quoting (fixes #1768) 2016-05-14 05:50:37 -04:00
mod-userdir.t [mod_user] add test cases to check handling of encoded ~ as %7E (#2124) 2013-06-29 10:07:45 +00:00
prepare.sh [core] encode path with ENCODING_REL_URI in redirect to directory (fixes #2661, thx gstrauss) 2015-11-07 15:00:18 +00:00
proxy.conf [tests] search for perl in PATH instead of /usr/bin; whitespace + test config cleanups 2015-08-22 20:51:08 +00:00
request.t [tests] add cleanup.sh to cmake test runs, reset SLOWREQUEST in request.t 2014-01-10 12:05:12 +00:00
run-tests.pl Fix request parser to handle packets with splitted \r\n\r\n (fixes #2105) 2009-11-29 14:13:13 +00:00
symlink.t mark testcase executable 2008-05-22 06:25:54 +00:00
var-include-sub.conf [tests] search for perl in PATH instead of /usr/bin; whitespace + test config cleanups 2015-08-22 20:51:08 +00:00
var-include.conf [tests] search for perl in PATH instead of /usr/bin; whitespace + test config cleanups 2015-08-22 20:51:08 +00:00
wrapper.sh Add static-file.disable-pathinfo option to prevent handling of urls like .../secret.php/image.jpg as static file 2011-08-30 22:13:59 +00:00