Skip to content
This repository has been archived by the owner on Dec 13, 2022. It is now read-only.

Commit

Permalink
enh(auth): autologin enhancement (#11956)
Browse files Browse the repository at this point in the history
Refs: MON-15384
  • Loading branch information
kduret authored Oct 7, 2022
1 parent 31bba6e commit 65d27b4
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions www/class/centreonAuth.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -202,6 +202,14 @@ protected function checkPassword($password, $token = "", $autoImport = false)
*/
private function checkAutologinKey($password, $token): void
{
if (
array_key_exists('contact_oreon', $this->userInfos)
&& $this->userInfos['contact_oreon'] !== '1'
) {
$this->passwdOk = self::PASSWORD_INVALID;
return;
}

if (
!empty($this->userInfos["contact_autologin_key"])
&& $this->userInfos["contact_autologin_key"] === $token
Expand Down

0 comments on commit 65d27b4

Please sign in to comment.