Req #52325 [Opn->Wfx]: multiple php.ini with mod_php5 allusive or impossible

From: Date: Mon, 02 Aug 2021 16:14:54 +0000
Subject: Req #52325 [Opn->Wfx]: multiple php.ini with mod_php5 allusive or impossible
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-235533@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=52325&edit=1 ID: 52325 Updated by: cmb@php.net Reported by: admin at digibase dot ca Summary: multiple php.ini with mod_php5 allusive or impossible -Status: Open +Status: Wont fix Type: Feature/Change Request Package: PHP options/info functions Operating System: Linux PHP Version: Irrelevant -Assigned To: +Assigned To: cmb Block user comment: N Private report: N New Comment: Since this feature request got no traction for more than ten years, and given that using a single Apache instance for multiple users isn't exactly best practice, I'm closing this ticket as WONTFIX. If anybody still feels this would be a good feature addition, please pursue the RFC process[1]. [1] <https://wiki.php.net/rfc/howto> Previous Comments: ------------------------------------------------------------------------ [2013-08-03 15:55:43] ben dot rubson at gmail dot com See summary bug #65386 ------------------------------------------------------------------------ [2010-07-13 10:31:42] admin at digibase dot ca Just as clarification: in my test cases, On one "restricted" vhost with options set via php.ini: On a "less restricted" vhost with options set via php.ini: these lines should be regarded as: On one "restricted" vhost with options set via /etc/php/profiles/default/php.ini: On a "less restricted" vhost with options set via /etc/php/profiles/approved/php.ini: ------------------------------------------------------------------------ [2010-07-13 10:22:46] admin at digibase dot ca Description: ------------ Greetings, I have noticed that under apache, setting php.ini-only directives (such as disable_functions - which is not accepted in httpd.conf) per virtual host can only be done by installing php with something like suPHP. This is not a desirable configuration in most cases when php is already installed as mod_php4 or mod_php5. Furthermore, for loading php.ini files, PHPRC environment variable seems to be ignored, as well, PHPINIDir only is accepted once per apache configuration, even in completely different vhost blocks. I run a shared hosting infastructure for special project sites, Now, I would like to have a default, restricted PHP configuration, then under certain virtual host blocks (for example, for users I approve) set up "less restricted" php.ini files for those accounts. Also, there are several internally run sites that need a very loose setup but I would not want regular users having that setup for themselves. The issue at the moment is for many options, PHP does not accept more than one setup per server (oncemore, in the case of disable_functions). Test script: --------------- <? system('ls'); ?> Expected result: ---------------- On one "restricted" vhost with options set via php.ini: The script should return that the system() function is disabled. On a "less restricted" vhost with options set via php.ini: The script should execute the system() call. Actual result: -------------- Either: On one "restricted" vhost with options set via php.ini: The script returns that the system() function is disabled. On a "less restricted" vhost with options set via php.ini: The script returns that the system() function is disabled. Or: On one "restricted" vhost with options set via php.ini: The script executes the system() call. On a "less restricted" vhost with options set via php.ini: The script executes the system() call. ------------------------------------------------------------------------ -- Edit this bug report at https://bugs.php.net/bug.php?id=52325&edit=1

« previous php.bugs (#235533) next »