Re: CGI and typing files by suffix

Tony Sanders (sanders@BSDI.COM)
Thu, 30 Dec 1993 11:30:14 -0600


> Does Plexus parse the URL by doing stats through the file system to
> find out where the "path/cmd" ends and the "args" begin? I find this
Plexus has an associative array:
map /man man.pl &do_man($top, $rest, $query)
So it just looks it up in the table and eval()'s it's contents. Having
a fixed table of allowed scripts has it's features (security) and drawbacks
(manual updates). However, I don't add scripts every day so I haven't
found it to be a problem myself.

> > The `;' scheme simply has too many drawbacks (namely you can't front-end
> > existing directory hierarchies with scripts).
> Could you explain this? What couldn't you do with the ';' scheme that
> you can with the current scheme?
Let's say I currently have the URLs:
http://server/man/1/ls
http://server/man/1/cat
...
Now, let's say I want to change this so that instead of a bunch of files
in the man directory I want to convert `man' to be a script (maybe I want
to generate the html on the fly, maybe I want to WAIS all the data and
provide a search engine as well as a browsing engine). With the ';' scheme
I would have to change all the URLs in the world that point to my data to
read "http://server/man;html1/ls" (many of which I do not own or even know
about). This is not acceptable. This is a real-life situation, I have
done this and I know several other people who have done it (converted
a directory hierarchy to use a search gateway).

The only advantage to ';' is that it's a little easier to parse. This
isn't a significant enough advancement that it's worth breaking the
script/non-script symmetry.

--sanders