php.net |  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
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
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 */

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2000-08-12 23:03 UTC] zeev@php.net
Already fixed in the CVS.  Thanks!
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sun Dec 22 11:01:30 2024 UTC