httpd-bugs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject DO NOT REPLY [Bug 50851] mod_proxy_fcgi does not comply with RFC 3875 (CGI 1.1)
Date Fri, 04 Mar 2011 17:55:31 GMT

--- Comment #7 from Mark Montague <> 2011-03-04 12:55:27 EST ---
Hi, Jim,

I just tested mod_fcgid 2.3.6 under httpd 2.3.10:

- with the example from the mod_fcgid manual, with FcgidFixPathinfo both
on and off

- with the phpinfo.php example form the mod_fcgid manual, running under php-cgi
(from PHP 5.3.6RC2), with FcgidFixPathinfo both on and off

In all four cases, constructing script-URI according to the formula in RFC 3875
gives the correct result.

I also studied the mod_fcgid source code, in particular fcgid_add_cgi_vars()
and fcgid_handler().  mod_fcgid creates the SCRIPT_NAME, PATH_INFO, and
PATH_TRANSLATED environment variables in the exact same way mod_proxy_fcgi does
in an unmodified httpd 2.3.10, by calling:


The reason this yields correct results in the case of mod_fcgid and mod_fcgi is
because those modules are executing scripts that reside in the filesystem and
URI namespace that httpd has access to, and the script name can be determined
during the location, directory, and file walks; the PATH_INFO is then the part
of the URI immediately after the script name.

However, a proxy server that is trying to "emulate" a CGI environment
(mod_proxy_fcgi, mod_proxy_sapi) is not able to determine what part of the URI
is the script name unless it has some insight into the origin server's URI

What about having the PATH_INFO CGI environment off by default for
mod_proxy_fcgi, unless the administrator asks httpd to put *something* there,
even if it might be wrong?  That is, a "addpathinfo" patch as opposed to a
"nopathinfo" patch?

Thanks for all the time you've been spending on this, and I apologize for
unexpectedly taking so much of your time.  Please let me know if there is
anything else I can research, test, or write.

Configure bugmail:
------- You are receiving this mail because: -------
You are the assignee for the bug.

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message