How to disallow use of disable_functions in?

Posted by Gaia on Server Fault See other posts from Server Fault or by Gaia
Published on 2012-06-29T22:53:40Z Indexed on 2012/06/30 3:17 UTC
Read the original article Hit count: 447

Filed under:
|
|
|
|

I'm obviously not the first one to have this problem, but I cannot not find an answer to this situation.

I want to lock down PHP a bit, more specifically the use disable_functions. The environment is CentOS 6.2/PHP 5.3.3 fcgid/Apache 2.2.15:

  1. Whats the proper apache config (AllowOverride, etc) to disable any PHP setting to be changed via .htaccess? All other overrides are ok (current setting is AllowOverride All)

  2. Whats the proper config to forbid effective use of disable_functions in all but the master php.ini (as in forbid use of disable_functions in /home/myvhost/etc/php5/php.ini or any directory within in that vhost public_html. another way to say this: the only effective disable_functions comes from the master php.ini)?

  3. If #2 is not possible, at least whats the proper config to disallow a vhost owner to effectively use any php.ini but the vhost main one (/home/myvhost/etc/php5/php.ini)?

Thanks

© Server Fault or respective owner

Related posts about apache2

Related posts about php