php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #161 ReadFile & File do not honour SAFE-MODE
Submitted: 1998-03-11 08:50 UTC Modified: 2007-05-21 23:42 UTC
From: benkovsk at pha dot pvt dot cz Assigned: rasmus (profile)
Status: Closed Package: *General Issues
PHP Version: 3.0b5 OS: Digital Unix v3.2D2
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 you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: benkovsk at pha dot pvt dot cz
New email:
PHP Version: OS:

 

 [1998-03-11 08:50 UTC] benkovsk at pha dot pvt dot cz
Hi,
I can read root owned files (/etc/passwd) with ReadFile()
or File() even if phtml file and dir is owned by
non-root user. phpinfo reports safemode=1. Include()
in the same script on the same file returns permission 
error, which is right.

BTW: Why there's not a Bug type 'Security'?

My config line:

./configure --with-apache=../apache_1.3b5 --with-config-file-path=/usr/internet/apache/conf --disable-debug --enable
-safe-mode --with-exec-dir=/usr/internet/apache/safe-bin --enable-memory-limit

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [1998-03-15 22:02 UTC] rasmus
Fixed.
Patch is available at: http://ca.php.net/cvsweb.cgi/fopen-wrappers.c?r1=1.14&r2=1.15
 [2007-05-21 23:42 UTC] davey@php.net
.
 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Wed Feb 05 17:01:30 2025 UTC