Till Brehm
2016-02-09 ca9ac33c8ac8e6fa2c695e37af627e747a332999
Fixed: Issue #3751 ISPConfig Login fails on Nginx servers in 3.1-dev version.
1 files modified
7 ■■■■■ changed files
interface/lib/app.inc.php 7 ●●●●● patch | view | raw | blame | history
interface/lib/app.inc.php
@@ -71,6 +71,13 @@
            $this->uses('session');
            $sess_timeout = $this->conf('interface', 'session_timeout');
            $cookie_domain = (isset($_SERVER['SERVER_NAME']) ? $_SERVER['SERVER_NAME'] : $_SERVER['HTTP_HOST']);
            // Workaround for Nginx servers
            if($cookie_domain == '_') {
                $tmp = explode(':',$_SERVER["HTTP_HOST"]);
                $cookie_domain = $tmp[0];
                unset($tmp);
            }
            $cookie_secure = ($_SERVER["HTTPS"] == 'on')?true:false;
            if($sess_timeout) {
                /* check if user wants to stay logged in */