LDAP Search Error: More than one matching user found

Post general support questions here that do not specifically fall into the Linux or Windows categories.

Moderators: Developers, Moderators

Post Reply
dominicl
Posts: 1
Joined: Thu Jun 16, 2011 5:18 pm

LDAP Search Error: More than one matching user found

Post by dominicl »

Hi folks

I have had LDAP up and working for authenticating users and administrators for Cacti however recently I started getting this error when trying to login:

LDAP Search Error: More than one matching user found

This is since a new user was added to the domain with a similar login name. Is there somewhere I can hack Cacti to do an exact match in that search? It looks like right now it is effectively searching for username* which will return multiple results.

Thanks in advance
User avatar
gandalf
Developer
Posts: 22383
Joined: Thu Dec 02, 2004 2:46 am
Location: Muenster, Germany
Contact:

Re: LDAP Search Error: More than one matching user found

Post by gandalf »

auth_login.php is the place to look at.
R.
9inchpianist
Posts: 2
Joined: Tue Aug 20, 2013 10:50 am

Re: LDAP Search Error: More than one matching user found

Post by 9inchpianist »

I know this is an old topic but it's at the top of google when searching for this error so I thought I would post my solution.

The suggested search filter for Active Directory is:

Code: Select all

(&(objectclass=user)(objectcategory=user)(userPrincipalName=<username>*))
I think the * at the end is design to allow the '@domain.name' to be found, but the problem with this approach is that it also matches other usernames that start the same so:
bob@domain.name
bob2@domain.name
etc....

My solution was to change the last attirbute from userPrincipalName to sAMAccountName and remove the wildcard which results in a search filter as follows:

Code: Select all

(&(objectclass=user)(objectcategory=user)(sAMAccountName=<username>))
This ensures only one match is found.
bentech4u
Posts: 13
Joined: Wed Dec 24, 2014 6:07 am

Re: LDAP Search Error: More than one matching user found

Post by bentech4u »

HI

please help me to achieve AD authentication. Actually i am struggling to make it working.

i am always getting

Code: Select all

05/15/2016 08:25:08 AM - AUTH LDAP_SEARCH: More than one matching user found
05/15/2016 08:25:08 AM - AUTH LOGIN: LDAP Error: More than one matching user found
Post Reply

Who is online

Users browsing this forum: No registered users and 0 guests