[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Trouble ahead for cgi-bin/debian directory



On Tue, 5 Nov 1996, Bruce Perens wrote:

bruce >From: Christoph Lameter <clameter@waterf.org>
bruce >> I noticed that
bruce >> http://localhost/cgi-bin/debian/xxxx
bruce >> was parsed as
bruce >> http://localhost/cgi-bin/debian?xxxx
bruce >
bruce >This isn't quite right. The ?xxx should be in the environment variable
bruce >$PATH_INFO. Isn't this a requirement of the CGI standard?

>From what I see WN doing: Everything after the filename in 
cgi-bin/file/PPPP or filename.cgi/PPPPP is a parameter to the script and
not the path for the cgi anymore. And this seems to be quite common
otherwise man2html would not use it.

bruce >Use your browser to touch http://cgi.debian.org/cgi-bin/bruce/foo .
bruce >Note the result says "Path: /foo". Look at the script in
bruce >/home/Archives/DebianWebMaster/cgi.debian.org/cgi-bin/bruce .
bruce >That is how a virtual pathname script should work.

The cgi bin is cgi-bin/bruce and the parameter is /foo right? Same as
http://cgi.debian.org/cgi-bin/bruce?/foo

That is exactly the problem.

bruce >I think you can fix this easily enough with _another_ CGI script rather
bruce >than the hack you have made to the web server. Put a CGI script in your
bruce >real cgi-bin that is called "debian". It should look like this:

I cannot unless I name the script "debian" for an url like

http://cgi-bin/debian/man2html

In this case the webserver is looking for a cgi bin in /cgi-bin with the
name of "debian" and passes "/man2html" as a parameter.

I have made a hack to man2html to insert a '?' between
cgi-bin/x/<pathname>. I have done nothing to the webserver in this
respect.

bruce >> I would suggest getting rid of cgi-bin/debian altogether and letting
bruce >> the webserver in update-debian-www make links in the real cgi-bin.
bruce >
bruce >It's possible, but more sloppy than I would like. Having the update-debian-www
bruce >put links into the primary cgi-bin means that the end-user must edit that
bruce >script if they want to turn off the automatic functionality. I'd rather have
bruce >it that the user need only remove a link or change a CGI path entry to remove
bruce >all of the automatic CGI scripts.

The end user can simply put files into the cgi-bin to override links.


--- +++ --- +++ --- +++ --- +++ --- +++ --- +++ --- +++ ---
PGP Public Key  =  FB 9B 31 21 04 1E 3A 33  C7 62 2F C0 CD 81 CA B5 

--
TO UNSUBSCRIBE FROM THIS MAILING LIST: e-mail the word "unsubscribe" to
debian-devel-REQUEST@lists.debian.org . Trouble? e-mail to Bruce@Pixar.com


Reply to: