fix bug with ldap login in metaconsole

This commit is contained in:
alejandro.campos@artica.es 2021-10-19 19:19:55 +02:00
parent 9d813b729e
commit e7d730ba0d
3 changed files with 7 additions and 7 deletions

View File

@ -387,7 +387,7 @@ function process_user_login_remote($login, $pass, $api=false)
$pass,
$user_info,
$permissions,
is_metaconsole()
is_metaconsole() && is_centralized() === false
);
}
} else {

View File

@ -1732,9 +1732,9 @@ function is_management_allowed($hkey='')
$nodes = (int) $nodes;
}
return ( (is_metaconsole() && (is_centrallised() || $nodes === 0))
|| (!is_metaconsole() && !is_centrallised())
|| (!is_metaconsole() && is_centrallised()) && $hkey == generate_hash_to_api());
return ( (is_metaconsole() && (is_centralized() || $nodes === 0))
|| (!is_metaconsole() && !is_centralized())
|| (!is_metaconsole() && is_centralized()) && $hkey == generate_hash_to_api());
}
@ -1743,7 +1743,7 @@ function is_management_allowed($hkey='')
*
* @return boolean
*/
function is_centrallised()
function is_centralized()
{
global $config;
@ -1763,7 +1763,7 @@ function is_centrallised()
*/
function is_central_policies()
{
return is_metaconsole() && is_centrallised();
return is_metaconsole() && is_centralized();
}

View File

@ -452,7 +452,7 @@ if (check_acl($config['id_user'], 0, 'ER')) {
$autorefresh_list_out = [];
if (is_metaconsole() === false || is_centrallised() === true) {
if (is_metaconsole() === false || is_centralized() === true) {
$autorefresh_list_out['operation/agentes/estado_agente'] = 'Agent detail';
$autorefresh_list_out['operation/agentes/alerts_status'] = 'Alert detail';
$autorefresh_list_out['enterprise/operation/cluster/cluster'] = 'Cluster view';