mirror of
https://github.com/Icinga/icingaweb2.git
synced 2025-07-28 00:04:04 +02:00
ExternalBackend: Don't authenticate a user if REMOTE_USER
is empty
This commit is contained in:
parent
52df0eb399
commit
668ae38497
@ -70,11 +70,11 @@ class ExternalBackend implements UserBackendInterface
|
||||
public static function getRemoteUser($variable = 'REMOTE_USER')
|
||||
{
|
||||
$username = getenv($variable);
|
||||
if ($username !== false) {
|
||||
if (! empty($username)) {
|
||||
return $username;
|
||||
}
|
||||
|
||||
if (array_key_exists($variable, $_SERVER)) {
|
||||
if (array_key_exists($variable, $_SERVER) && ! empty($_SERVER[$variable])) {
|
||||
return $_SERVER[$variable];
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user