|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #6135 mod_php4 HTTP_SERVER_VARS broken (patch included)
Submitted: 2000-08-12 22:24 UTC Modified: 2000-08-12 23:03 UTC
From: eric dot kidd at pobox dot com Assigned:
Status: Closed Package: Other
PHP Version: 4.0.1pl2 OS: RedHat Linux 6.2
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
Block user comment
Status: Assign to:
Bug Type:
From: eric dot kidd at pobox dot com
New email:
PHP Version: OS:


 [2000-08-12 22:24 UTC] eric dot kidd at pobox dot com
mod_php4 sets up HTTP_SERVER_VARS incorrectly. This problem occurs when:

* You're using mod_php4 with Apache
* register_globals is off.

What happens:

* You can still access PHP_SELF and PATH_TRANSLATED.
* All other members of HTTP_SERVER_VARS are missing.

To fix this bug, apply the following patch to PHP 4.0.1pl2:

--- sapi/apache/mod_php4.c-old	Sat Aug 12 21:58:57 2000
+++ sapi/apache/mod_php4.c	Sat Aug 12 21:59:20 2000
@@ -255,7 +255,7 @@
 		} else {
 			val = empty_string;
-		php_register_variable(elts[i].key, val, NULL ELS_CC PLS_CC);
+		php_register_variable(elts[i].key, val, track_vars_array ELS_CC PLS_CC);
 	/* insert special variables */


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2000-08-12 23:03 UTC]
Already fixed in the CVS.  Thanks!
PHP Copyright © 2001-2023 The PHP Group
All rights reserved.
Last updated: Sun Feb 05 01:03:38 2023 UTC