httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stas Bekman <s...@stason.org>
Subject Re: Please define "canonicalize" in httpd.h
Date Sun, 01 Aug 2004 19:35:59 GMT
John Rowe wrote:
>>Please define "canonicalize" 
> 
> 
> If the same thing can be referred to by a number of different names and
> the convention is that one is the "one true", or canonical, name and the
> others are mere aliases then canonicalisation (or canonicalization for a
> non-Brit) is the process of translating a name into the canonical name
> of that object. Of course this assumes that no two objects can have the
> same name.
> 
> In the context of case-insensitive file systems, it's often the case
> that a file is given the canonical name that it was created with
> ("MyFile") with all other capitalisations ("myfile", "myfilE") being
> alternative names for the same filename. 
> 
> Of course, the situation is complicated not only by symlinks but also
> that in unix the same file can have many filenames. The normal
> canonicalisation for a file, as opposed to filename, is (device, inode
> number) but that's not always very useful: for security reasons you
> can't actually open a file from its device and inode number.

Thanks John. I understand all that. My request was to fix the following 
XXX in httpd.h:

struct request_rec {
  ...
     /* XXX: What does this mean? Please define "canonicalize" -aaron */
     /** The true filename, we canonicalize r->filename if these don't 
match */
     char *canonical_filename;

and explain there when one should use canonical_filename, instead of 
filename. The comment:

/** The true filename, we canonicalize r->filename if these don't match */

suggests that r->filename is getting canonized as well.

-- 
__________________________________________________________________
Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/     mod_perl Guide ---> http://perl.apache.org
mailto:stas@stason.org http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org   http://ticketmaster.com

Mime
View raw message