safe_mode_gid boolean
By default, Safe Mode does a UID compare check when opening files. If you want to relax this to a GID compare, then turn on safe_mode_gid. Whether to use UID (FALSE) or GID (TRUE) checking upon file access.
http://www.php.net/manual/en/features.safe-mode.php
Other than that consider turning off safe mode if you have access to it, or turn it off for your virtual host.
Jason
Paul Chvostek wrote:
I've got a script whose configuration creates a storage directory owned by the web server in which files get stored, also owned by the web server. With safe_mode in effect, I'm getting errors like:
Warning: file_exists() [function.file-exists]: SAFE MODE Restriction in effect. The script whose uid is 10054 is not allowed to access /path/to/some/data owned by uid 80 in /path/to/some/file.php on line 111
Wouldn't it make sense for safe_mode also to allow read access to files owned by the web server's process as well as the directory owner's?
Obviously, a process running as uid 80 won't be able to suid to another user. If I make the directory owned by the user, the files will be inaccessible, but if I make the directory uid 80, then *it* will be inaccessible.
Is there some other solution to storing (and then retrieving) files with safe_mode on?
Thanks.
-- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php