By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,964 Members | 1,290 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,964 IT Pros & Developers. It's quick & easy.

How to set BASH variable form PHP which is working in safe_mode ?

P: n/a
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.
Jul 17 '05 #1
Share this question for a faster answer!
Share on Google+

This discussion thread is closed

Replies have been disabled for this discussion.