[opw-web] Revert "Add config variable to force on HTTP_X_FORWARDED_PROTO=https"



commit 125abc8a70d4a3c6bc0b2db769f6140225384071
Author: Owen W. Taylor <otaylor fishsoup net>
Date:   Tue Mar 18 22:56:51 2014 -0400

    Revert "Add config variable to force on HTTP_X_FORWARDED_PROTO=https"
    
    Trying to set HTTP_X_FORWARDED_PROTO via index.php doesn't work because
    the auth code runs outside of index.php - it's better to simply set it
    in the apache config with the SetEnv directive.
    
    This reverts commit 645486c0a02ee318828119c11f031d4700242b7e.

 classes/class_config.php |    2 --
 config.sample.php        |    5 -----
 init.php                 |    3 ---
 3 files changed, 0 insertions(+), 10 deletions(-)
---
diff --git a/classes/class_config.php b/classes/class_config.php
index 93f73af..4a59ee6 100644
--- a/classes/class_config.php
+++ b/classes/class_config.php
@@ -35,7 +35,6 @@ class config
 
     var $webmaster;
     var $http_host;
-    var $https_force_forwarded_proto;
     var $skin_name;
     var $lang_name;
     var $per_page;
@@ -120,7 +119,6 @@ class config
             $this->site_copyright   = isset($site_copyright) ? $site_copyright : '&copy; 2012 KDE';
             $this->webmaster        = isset($webmaster) ? $webmaster : '';
             $this->http_host        = isset($http_host) ? $http_host : '';
-            $this->https_force_forwarded_proto = isset($https_force_forwarded_proto) ? 
$https_force_forwarded_proto : '';
             $this->skin_name        = isset($skin_name) ? $skin_name : 'Neverland';
             $this->lang_name        = isset($lang_name) ? $lang_name : 'en-gb';
             $this->per_page         = isset($per_page) ? $per_page : 10;
diff --git a/config.sample.php b/config.sample.php
index 8ae44ba..529d1e4 100644
--- a/config.sample.php
+++ b/config.sample.php
@@ -63,11 +63,6 @@ $site_copyright = "&copy; KDE Webteam and GNOME Foundation";
 // Webmaster's email address
 $webmaster = "webmaster gnome org";
 
-// If set, this causes the HTTP_X_FORWARDED_PROTO server variable to be set
-// to 'https' in the server environment; this is basically a workaround for
-// some config problem with the GNOME setup.
-$https_force_forwarded_proto = false;
-
 // Name of current skin
 $skin_name = "Neverland";
 
diff --git a/init.php b/init.php
index d854b2c..ac68bba 100644
--- a/init.php
+++ b/init.php
@@ -35,9 +35,6 @@ include_once('classes/class_donut.php');
 $config = new config();
 $gsod = new gsod();
 
-if ($config->https_force_forwarded_proto)
-  $_SERVER['HTTP_X_FORWARDED_PROTO'] = 'https';
-
 // Instantiate general classes
 $core   = new core();
 $db     = new db();


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]