Nagios LDAP用户pager被清空问题
*****************************************************************************************************************
LDAP用户每次登录时会把LDAP登记的邮件、手机等最新信息自动更新到contact表中,由于目前LDAP中没有输入手机号,因此每次LDAP用户登录都把contact中手工输入的手机号清空。
更改如下PHP源程序,手机信息不进行处理。
/usr/local/centreon/www/class/centreonAuth.LDAP.class.php
/* $queryUpdateExtInfos = "UPDATE contact SET
* contact_ldap_dn = '" . $this->pearDB->escape($userDn, false) . "',
* contact_name = '" . $this->pearDB->escape($userDisplay, false) . "',
* contact_email = " . $userEmail . ",
* contact_pager = " . $userPager . ",
* ar_id = ".$this->arId."
* WHERE contact_id = " . $this->contactInfos['contact_id'];
*/
$queryUpdateExtInfos = "UPDATE contact SET
contact_ldap_dn = '" . $this->pearDB->escape($userDn, false) . "',
contact_name = '" . $this->pearDB->escape($userDisplay, false) . "',
contact_email = " . $userEmail . ",
ar_id = ".$this->arId."
WHERE contact_id = " . $this->contactInfos['contact_id'];