Details
-
Bug
-
Resolution: Fixed
-
Major
-
None
-
None
-
Debian GNU/Linux 7 (wheezy), Observium r5164, Windows Active Directory (servers 2008, 2008 r2, 2012)
Description
When logging in using LDAP authentication access level is always 0.
I have narrowed this down to auth_user_level function not being called or exiting at the if statement.
The easiest way for me to confirm this was to add a
print_debug(echo("auth_user_level is running"));
|
just inside the if and enable debugging. While the rest of the LDAP debugging displayed, this never echoed to the screen, the group(s) never displayed, and the user(s) never were granted an access level higher than 0
I have attached the sanitized ldap section of my config.php. I altered none of the lines beyond swapping domain names and passwords.
I guess that the actual problem is that there is a backslash in there to escape a comma, but in Active directory the backslash in a LDAP filter needs to be represented by it's hex equivalent https://social.technet.microsoft.com/wiki/contents/articles/5312.active-directory-characters-to-escape.aspx#LDAP_Filters in order to match. By adding slashes, escaping, the backslash in the existing \5C it preserves the filter.