[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Chicken-users] scgi with lighttpd
From: |
Thomas Chust |
Subject: |
Re: [Chicken-users] scgi with lighttpd |
Date: |
Mon, 25 Sep 2006 22:05:04 +0200 |
On Sun, 24 Sep 2006, Ashish Shrestha wrote:
[...] Don't know the reasons for it but I think, specially for those
using lighttpd, it would be more helpful to use script_name or
request_uri rather than path_info as path_info is always empty. [...]
Hello Ashish,
at the moment I don't have lighttpd installed to test this, but I will
look into the problem as soon as I find the time.
If I understand the CGI standard document correctly, though, the
situation is as follows:
* SCRIPT_NAME should be set to the path part of the URL of the executed
handler program, *not including* any user supplied suffix to the URL.
* PATH_INFO should be set to the value of SCRIPT_NAME plus all
components of the URL appended by the user.
* PATH_TRANSLATED should be set to something equivalent to PATH_INFO
after URL rewriting rules have been applied.
* REQUEST_URI is not defined in the CGI standard.
Considering this information, the only variable that seemed sensible to
use for dispatching to different handlers in an SCGI program was PATH_INFO
and the behaviour you describe for lighttpd looks buggy to me.
Using PATH_INFO is also apparently the only working choice when using the
Apache SCGI client module in my fairly standard Apache configuration.
On the other hand I am fully aware that the CGI standard is pretty unclear
in many points, the SCGI standard doesn't say much about "environment"
variables at all and that each web server does things differently...
I guess that making SCGI more portable beyond the Apache SCGI module which
I used for testing will require some hacks to determine the client web
server and use different environment values accordingly :-(
cu,
Thomas