php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #37720 merge_php_config scrambles values when using DirectoryMatch / VirtualHost
Submitted: 2006-06-06 22:05 UTC Modified: 2006-06-09 15:16 UTC
From: pumuckel at metropolis dot de Assigned:
Status: Closed Package: Apache2 related
PHP Version: 5.1.4 OS: Linux
Private report: No CVE-ID: None
 [2006-06-06 22:05 UTC] pumuckel at metropolis dot de
Description:
------------
When using DirectoryMatch in httpd.conf / .htaccess and virtualHost entries, then php_values inside those directives get scrambled. The reason seems likely to be that in merge_php_config the new_conf parameter gets modified even this is strictly forbidden by apache2 api!

Solution: Make a copy of new_conf (with proper hash initialization) and return a pointer to the new copy.


Reproduce code:
---------------
I can provide a testcase configuration on request.

Expected result:
----------------
The configuration parameters should be as configured.

Actual result:
--------------
Configuration is mixed occasionally.

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2006-06-06 22:16 UTC] tony2001@php.net
>I can provide a testcase configuration on request.
Please upload it somewhere and put the link here.

>Configuration is mixed occasionally.
It'd be good to have a couple of examples.
 [2006-06-07 11:16 UTC] pumuckel at metropolis dot de
First, this is apache2 related, i have modified bug category appropriate.

Second: A testcase is located at http://www.metropolis-ag.de/downloads/bug37720.tgz

Please read the README file within this archive, which explains steps to reproduce the bug.

Also attached in the README is a possible (but incomplete) patch for 5.1.4. Please contact me via email if you have any questions / need to discuss things.
 [2006-06-09 15:16 UTC] mike@php.net
This bug has been fixed in CVS.

Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at
http://snaps.php.net/.
 
Thank you for the report, and for helping us make PHP better.


 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Dec 05 11:01:29 2024 UTC