Alvaro Lopez Ortega dijo [Thu, Apr 17, 2008 at 08:55:12PM +0200]:
> The usual solution is to call access() to check whether the program is  
> allowed to access the file, but in the case of Cherokee I do not think  
> it is worth using it because of the performance penalty. I would  
> rather keep it trying to read it and handling the failure in case it  
> could access the file.

I fully agree on Álvaro here. Besides, there are several different
extended permission systems in (not-as-wide-as-Unix's-but-still) use,
and access() might not be able to give the full information -
i.e. while access() follows symlinks in Unix, it won't follow the
whatsitsname equivalents in Windows, as they are plain files.

In Unix, the user you run as should determine the
permissions. Remember that people can do strange and ingenious things
via FUSE (i.e. an example of a VERY bad interface design, but still a
convenient way to work under some circumstances is FlickrFS - Files
might just appear and disappear from under your feet with no prior
warning as tags/sets are created/deleted/modified). There are
filesystems based on SMB, even on SSH, which also carry some strangish
semantics... And Cherokee is not who should determine what is readable
and what is not.

-- 
Gunnar Wolf - [EMAIL PROTECTED] - (+52-55)5623-0154 / 1451-2244
PGP key 1024D/8BB527AF 2001-10-23
Fingerprint: 0C79 D2D1 2C4E 9CE4 5973  F800 D80E F35A 8BB5 27AF
_______________________________________________
Cherokee mailing list
[email protected]
http://cherokee-project.com/cgi-bin/mailman/listinfo/cherokee

Reply via email to