[Pmwiki-users] Warning : SAFE MODE Restriction

Patrick R. Michaud pmichaud at sci.tamucc.edu
Mon Mar 24 12:22:43 CST 2003


Louis and others-

There's currently a problem with running PmWiki on systems with PHP versions
4.3.0 and later in "safe mode", and this looks to be the problem you're
experiencing below.  I don't have a good fix at the moment, other than
to note that I think the PHP designers have really screwed up on this
particular issue.

The problem is that PHP 4.3.x in safe mode allows scripts (such as
pmwiki.php) to create files, but the script cannot subsequently read or 
access any files it has created.  Yes, that's right--in safe mode
pmwiki.php is not permitted to access any of the files it has created.

For now the solution is to have "safe mode" turned off if possible.
Some hosting providers may be reluctant to do this--to which I would
simply point out that PHP with safe mode turned off is really no
more or less secure than any other CGI script (e.g., in Perl).
I'm working on redesigning PmWiki so that it can run within safe_mode
but the fix doesn't appear to be a simple one.

Pm


On Mon, 24 Mar 2003, Louis Katz wrote:

> Hi, I am trying to install on a system that gives me ssh access. I can 
> apparently change the permissions to 2777 .  . The permissions read 
> drwxrwsrwx . I wonder if there is some way I can manually configure 
> pmwiki rather than running the installation script. Or if there is some 
> other work around.
> Thanks,
> Louis
> lkatz at falcon.tamucc.edu
>   Here is the text of the error message:
> 
> Warning :  SAFE MODE Restriction in effect.  The script whose uid is 
> 615 is not allowed to access 
> /home/virtual/site106/fst/var/www/html/w/wiki.d owned by uid 48 in 
> /home/virtual/site106/fst/var/www/html/w/pmwiki.php on line 409
> 
> Warning :  fopen("wiki.d/.flock", "w") - No such file or directory in 
> /home/virtual/site106/fst/var/www/html/w/pmwiki.php on line 409
> 
> Warning :  Cannot add header information - headers already sent by 
> (output started at 
> /home/virtual/site106/fst/var/www/html/w/pmwiki.php:409) in 
> /home/virtual/site106/fst/var/www/html/w/pmwiki.php on line 250
> 
> Warning :  Cannot add header information - headers already sent by 
> (output started at 
> /home/virtual/site106/fst/var/www/html/w/pmwiki.php:409) in 
> /home/virtual/site106/fst/var/www/html/w/pmwiki.php on line 251
> 
> Warning :  Cannot add header information - headers already sent by 
> (output started at 
> /home/virtual/site106/fst/var/www/html/w/pmwiki.php:409) in 
> /home/virtual/site106/fst/var/www/html/w/pmwiki.php on line 252
> 
> Warning :  Cannot add header information - headers already sent by 
> (output started at 
> /home/virtual/site106/fst/var/www/html/w/pmwiki.php:409) in 
> /home/virtual/site106/fst/var/www/html/w/pmwiki.php on line 253
> 
> PmWiki can't process your request
> Cannot acquire lockfile
> 
> We are sorry for any inconvenience.
> 





More information about the pmwiki-users mailing list