php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #23317 fopen and touch fail in safe_mode
Submitted: 2003-04-23 10:23 UTC Modified: 2003-04-23 11:01 UTC
From: patrick_cossette1 at uqtr dot ca Assigned:
Status: Not a bug Package: Filesystem function related
PHP Version: 4.3.1 OS: AIX 4.3.3
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If this is not your bug, you can add a comment by following this link.
If this is your bug, but you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: patrick_cossette1 at uqtr dot ca
New email:
PHP Version: OS:

 

 [2003-04-23 10:23 UTC] patrick_cossette1 at uqtr dot ca
This is be similiar to bug #21958 but not the same OS and not the same PHP version.

With AIX 4.3.3 and PHP 4.3.1.

With safe_mode on , I cannot create a file with neither touch nor fopen nor mkdir. (With safe_mode off, the creation works).

Apache is running under user "web" and group "web".
I have the directory /web/hee_dev whose owner is web.web with permissions rwxr-s---

I have the script testing.php located in that directory:

   <?
     $fp=fopen("filetocreate","w+");
   ?>

If the file "filetocreate" does not already exist, I get the following error while executing the script:
 
           Warning: Unable to access filetocreate  
           in /web/hee_dev/testing.php on line 2

           Warning: fopen("filetocreate", "w+") - No such 
           file or directory in /web/hee_dev/testing.php on 
           line 2

If the file already exists, I can open it without any problem.

I had read somewhere in the bug database that this should be solved by now, but with 4.3.1, it still produces this error.


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2003-04-23 11:01 UTC] sniper@php.net
Please do not submit the same bug more than once. An existing
bug report already describes this very problem. Even if you feel
that your issue is somewhat different, the resolution is likely
to be the same. Because of this, we hope you add your comments
to the existing bug instead.

Thank you for your interest in PHP.

Just add your comments in bug #21958

 
PHP Copyright © 2001-2020 The PHP Group
All rights reserved.
Last updated: Fri Sep 25 07:01:23 2020 UTC