phpCAS
phpCAS copied to clipboard
_isHttps bug?
Client.php line:3617
if (!empty($_SERVER['HTTP_X_FORWARDED_PROTO'])) {
return ($_SERVER['HTTP_X_FORWARDED_PROTO'] === 'https');
} elseif (!empty($_SERVER['HTTP_X_FORWARDED_PROTOCOL'])) {
return ($_SERVER['HTTP_X_FORWARDED_PROTOCOL'] === 'https');
} elseif ( isset($_SERVER['HTTPS'])
&& !empty($_SERVER['HTTPS'])
&& strcasecmp($_SERVER['HTTPS'], 'off') !== 0
) {
return true;
}
return false;
sometimes , domain may cross two proxy layers . so the HTTP_X_FORWARDED_PROTO will be set "https,https". i think , the project should support this state :)
Might make sense to check if the variable begins with 'https' since this is the only relevant part I would think.