note 49181 added to features.safe-mode
| From: | bedek at o2 dot pl | Date: | Wed, 19 Jan 2005 07:44:55 +0000 |
| Subject: | note 49181 added to features.safe-mode | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-83608@lists.php.net to get a copy of this message | ||
Hello
How to set BASH variable form PHP which is working in "safe_mode" ?
... and to check if it's set for sure ?
I find out that I should create directory for binaries in home
direcotry of user and assign this direcotry to PHP variable -
safe_mode_exec_dir
Then I've copyed to this direcotry "/usr/local/bin/bash" and
"/usr/bin/grep".
This works fine WITHOUT "safe_mode":
PHP code:
<?php
system('BOOM=blowwww && set | grep BOOM');
?>
it returns:
BOOM=blowwww
but in "safe_mode" there is no output in web-browser and no errors
appear in error log file.
----
Manual Page -- http://www.php.net/manual/en/features.safe-mode.php
Edit -- http://master.php.net/manage/user-notes.php?action=edit+49181
Delete: added to the manual -- http://master.php.net/manage/user-notes.php?action=delete+49181&report=yes&reason=added+to+the+manual
Delete: bad code -- http://master.php.net/manage/user-notes.php?action=delete+49181&report=yes&reason=bad+code
Delete: spam -- http://master.php.net/manage/user-notes.php?action=delete+49181&report=yes&reason=spam
Delete: useless -- http://master.php.net/manage/user-notes.php?action=delete+49181&report=yes&reason=useless
Delete: other reasons -- http://master.php.net/manage/user-notes.php?action=delete+49181&report=yes
Reject -- http://master.php.net/manage/user-notes.php?action=reject+49181&report=yes
Search -- http://master.php.net/manage/user-notes.php