|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2005-03-31 16:13 UTC] php-bugs at lists dot php dot net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sat Oct 25 18:00:02 2025 UTC |
php3.ini as follows safe_mode=1 safe_mode_exec_string=/www/sites/mysite/cgi-bin doc_root=/www/sites/mysite open_basedir=/www/sites/mysite extension=pgsql.so test.php3 <?php copy("/etc/passwd","passwd"); /* this works */ $fd=fopen("passwd","r"); /* so does this */ fclose($fd); /* and this */ $fd=fopen("/etc/passwd","r"); /* this does is not successful */ fclose($fd); /* as it should not be */ ?> So the system will allow me to copy the passwd file to a local allowd directory and then open it which bypasses the fact that I have restricted the system with open_basedir directive. thanks