|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #72253 phpinfo shows only first block of admin_value[disable_functions]
Submitted: 2016-05-22 20:45 UTC Modified: 2016-06-05 04:45 UTC
From: witekfl at gazeta dot pl Assigned:
Status: Open Package: FPM related
PHP Version: 7.0.6 OS: Linux
Private report: No CVE-ID: None
Have you experienced this issue?
Rate the importance of this bug to you:

 [2016-05-22 20:45 UTC] witekfl at gazeta dot pl
phpinfo's disable_functions displays only first block of php_admin_value[disable_functions].

Test script:
php_admin_value[disable_functions] = curl_init
php_admin_value[disable_functions] = curl_close


Expected result:
phpinfo in disable_functions displays curl_init, curl_close

Actual result:


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2016-05-22 21:04 UTC]
-Status: Open +Status: Not a bug
 [2016-05-22 21:04 UTC]
php_admin_value defines a setting that cannot be overridden. The second line is ignored because it is attempting to override the disable_function set earlier.

disable_functions is a comma-separated list of functions. Your configuration should read
  php_admin_value[disable_functions] = curl_init,curl_close
 [2016-05-23 14:52 UTC] witekfl at gazeta dot pl
php_admin_value[disable_functions] = leak                                                                                                     
php_admin_value[disable_functions] = phpinfo                                                                                                  
php_admin_value[disable_functions] = exec

Warning: phpinfo() has been disabled for security reasons in /home/www/info.php on line 3

Could you check it first, please?
 [2016-05-23 17:41 UTC]
-Status: Not a bug +Status: Re-Opened
 [2016-05-23 17:41 UTC]
reproducible on 7.0.5 CLI as well:

php -n -d "disable_functions=phpinfo" -d "disable_functions=exec" -r "phpinfo();echo exec('ls');" | grep disable_

disable_functions => exec => exec
 [2016-05-23 17:43 UTC]
-Status: Re-Opened +Status: Not a bug
 [2016-05-23 17:43 UTC]
Disregard my last comment.
 [2016-05-23 19:09 UTC]
-Status: Not a bug +Status: Feedback
 [2016-05-23 19:09 UTC]
If you do
what does phpinfo() say, what does ini_get("disable_functions") return, and which of those functions do/do not work?
 [2016-05-23 19:31 UTC] witekfl at gazeta dot pl
echo 'disable_functions=', ini_get('disable_functions'), "\n";
echo 'sin(0)=', sin(0), "\n";
echo 'cos(0)=', cos(0), "\n";
echo 'tan(0)=', tan(0), "\n";

 disable_functions=sin sin(0)=                                                                                                              
   Warning: sin() has been disabled for security reasons in /home/www/v2.6.5/info.php on line 4                                               
   Warning: cos() has been disabled for security reasons in /home/www/v2.6.5/info.php on line 5                                               
   Warning: tan() has been disabled for security reasons in /home/www/v2.6.5/info.php on line 6
 [2016-06-05 04:22 UTC] php-bugs at lists dot php dot net
No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Re-Opened". Thank you.
 [2016-06-05 04:45 UTC]
-Status: No Feedback +Status: Open
 [2019-08-28 16:39 UTC] php-bugs at lists dot php dot net
This case has been reopened as of 8/29/2019 @ 1:01AM. Please comment any new information here. Otherwise, send an email directly
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Tue Apr 23 01:01:28 2024 UTC