You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Full Name and mail are not propagated to user profile when new user is connecting to cacti thru AD credentials in Multiple AD LDAP mode (creating user from template user)
To Reproduce
Steps to reproduce the behavior:
Configure Multiple AD LDAP domain with MS Active Directory
Domains Type Active Directory
User Template AD-user-temp
Protocol Version 3
Encryption SSL
Mode Specific Searching
Require Group Membership ON
LDAP CN Settings
Full Name cn
eMail mail
Login with new user credentials (user must be in the required AD user group)
Go to Console -> Configuration -> users .
There will be no Fullname and email in user properties.
Expected behavior
Full Name and mail must be propagated from Active Directory.
Desktop (please complete the following information)
I have made this change to code, it resolves the issue:
@cacti:/usr/share/cacti/site# diff auth_login_old.php auth_login.php
527c527,528< $ldap_cn_search_response = cacti_ldap_search_cn($username, array($cn_full_name,$cn_email) );---> # $ldap_cn_search_response = cacti_ldap_search_cn($username, array($cn_full_name,$cn_email) );> $ldap_cn_search_response = domain_ldappp_search_cn($username, array($cn_full_name,$cn_email),get_nfilter_request_var('realm')-1000);622a624,671> }>>> function domain_ldappp_search_cn($username, $cn = array(), $realm) {>> $ldap = new Ldap;>>> if (!empty($username)) $ldap->username = $username;>> $ld = db_fetch_row_prepared('SELECT *> FROM user_domains_ldap> WHERE domain_id = 1',> array($realm-1000));>> if (cacti_sizeof($ld)) {> if (!empty($ld['dn'])) $ldap->dn = $ld['dn'];> if (!empty($ld['server'])) $ldap->host = $ld['server'];> if (!empty($ld['port'])) $ldap->port = $ld['port'];> if (!empty($ld['port_ssl'])) $ldap->port_ssl = $ld['port_ssl'];> if (!empty($ld['proto_version'])) $ldap->version = $ld['proto_version'];> if (!empty($ld['encryption'])) $ldap->encryption = $ld['encryption'];> if (!empty($ld['referrals'])) $ldap->referrals = $ld['referrals'];>> if (!empty($ld['mode'])) $ldap->mode = 2;> if (!empty($ld['search_base'])) $ldap->search_base = $ld['search_base'];> if (!empty($ld['search_filter'])) $ldap->search_filter = $ld['search_filter'];> if (!empty($ld['specific_dn'])) $ldap->specific_dn = $ld['specific_dn'];> if (!empty($ld['specific_password'])) $ldap->specific_password = $ld['specific_password'];>> if ($ld['group_require'] == 'on') {> $ldap->group_require = true;> } else {> $ldap->group_require = false;> }>>>> if (!empty($ld['group_dn'])) $ldap->group_dn = $ld['group_dn'];> if (!empty($ld['group_attrib'])) $ldap->group_attrib = $ld['group_attrib'];> if (!empty($ld['group_member_type'])) $ldap->group_member_type = $ld['group_member_type'];> }>> if (!empty($cn)) $ldap->cn = $cn;>>>> return $ldap->Getcn();
The text was updated successfully, but these errors were encountered:
I reviewed your pull request. There are some typo's the biggest one being that you mis-spelled the function call in auth_login.php. Take a read. I'll leave it to @netniV 's discretion on whether or not it makes it into 1.2.21 or 1.2.22.
netniV
changed the title
Cacti 1.2.16 Multiple AD LDAP Full Name and mail are not propagated when creating user from template
When creating user from template, multiple Domain FullName and Mail are not propagated
Aug 14, 2022
Describe the bug
Full Name and mail are not propagated to user profile when new user is connecting to cacti thru AD credentials in Multiple AD LDAP mode (creating user from template user)
To Reproduce
Steps to reproduce the behavior:
Domains Type Active Directory
User Template AD-user-temp
Protocol Version 3
Encryption SSL
Mode Specific Searching
Require Group Membership ON
LDAP CN Settings
Full Name cn
eMail mail
Login with new user credentials (user must be in the required AD user group)
Go to Console -> Configuration -> users .
There will be no Fullname and email in user properties.
Expected behavior
Full Name and mail must be propagated from Active Directory.
Desktop (please complete the following information)
I have made this change to code, it resolves the issue:
The text was updated successfully, but these errors were encountered: