Edit report at https://bugs.php.net/bug.php?id=65351&edit=1
ID: 65351 Comment by: az9901 at gmail dot com Reported by: az9901 at gmail dot com Summary: enable_functions directive Status: Open Type: Feature/Change Request Package: PHP options/info functions PHP Version: 5.4.17 Block user comment: N Private report: N New Comment: According to the tests I did, "php_admin_value disable_functions" does not overwrite / redefine the global list, but complete it. I think that having the ability to declare white lists would make functions management easier. For example, let's assume we have excluded 40 functions globally ! We need the exec function in one of our virtualhosts. Instead of having to re-declare 39 functions in the virtualhost (which does not seem to work), we would simply have to make declare : "php_admin_value enable_functions exec" Easier to manage, especially for envs with several / many virualhosts. And so it would make the functions' management more secure. Thank you very much ! Previous Comments: ------------------------------------------------------------------------ [2013-07-28 23:39:46] yohg...@php.net Rather than mixing white and black list, redefine black list for certain virtual hosts. Users may use multiple php_admin_flag/value for the same setting to override previous definitions in server contexts. ------------------------------------------------------------------------ [2013-07-28 19:31:19] az9901 at gmail dot com What I tried to do : Keep a global (CG) array of pointers to the original functions for the ones which have been disabled (in the zend_API.c file, zend_disable_function function) ; Move functions' pointer to their original version for re-enabled ones (in the mod_php5.c file, send_php function). But I did not manage to get it working. And I don't know if it's the right way to implement it. Thank you ! ------------------------------------------------------------------------ [2013-07-28 19:18:34] az9901 at gmail dot com Description: ------------ Hello, I tried all the WE to implement enable_functions directive, but without success... Goal is to re-enable some functions in a specific Apache virtualhost which would have been disabled globally. We would then be able to be very restrictive in the global php.ini configuration file and allow some specific functions in some of the virtualhosts using "php_admin_value enable_functions ...". Could you please implement it ? Thank you very much ! Best regards, Ben ------------------------------------------------------------------------ -- Edit this bug report at https://bugs.php.net/bug.php?id=65351&edit=1