From 6d72cc522bd808901ea19b701d8d5cbf2a610476 Mon Sep 17 00:00:00 2001 From: Benjamin Sonntag Date: Wed, 7 Jun 2017 14:31:30 +0200 Subject: [PATCH] adding x-forwarded-proto = https management to detet https too --- bureau/class/config.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/bureau/class/config.php b/bureau/class/config.php index 63b75341..6af94001 100755 --- a/bureau/class/config.php +++ b/bureau/class/config.php @@ -167,6 +167,9 @@ $err = new m_err(); $authip = new m_authip(); $hooks = new m_hooks(); +if (!isset($_SERVER["HTTP_X_FORWARDED_PROTO"]) && $_SERVER["HTTP_X_FORWARDED_PROTO"]=="https") { + $_SERVER["HTTPS"]="on"; +} // https: Redirection if not calling https://!fqdn or if https is forced if ((variable_get('force_https', '0', "This variable is set to 0 (default) if users can access the management desktop through HTTP, otherwise we force HTTPS")&&(!isset($_SERVER["HTTPS"])|| ($_SERVER["HTTPS"] != "on")))) {