1

I have an Apache server on RHEL 6 that uses our active directory for authentication and when we added a new "LocationMatch"

AuthLDAPURL ldap://ad.company.com/DC=ad,DC=company,DC=com?samaccountname?sub?(memberOf=CN=RnD,CN=Users,DC=domain,DC=com)

and on this location we get error 500

on other location matches :

AuthLDAPURL ldap://ad.company.com:389/OU=MA,DC=ad,DC=company,DC=com?samaccountname

it works flawlessly.

рüффп
  • 620
  • 1
  • 11
  • 25

1 Answers1

0

I am having exact same problem today, without a "ou=", AuthLDAPURL will return a 500 error.

Finally found a url: http://clabs.org/blog/RawStuff

It mentioned: "

If you need to authenticate against different OUs, then there are two options. Ideally, simply changing the ldap url to work from the root should work:

AuthLDAPURL "ldap://eiadserver1.einstruction.com:389/DC=einstruction,DC=com?sAMAccountName?sub?(objectClass=user)"

However, against Active Directory this doesn't seem to work, because in addition to the search results, it will also return referrals to other directory partitions, and Apache can't grok these or somesuch. A bug has been filed for this, and the report includes a patch.

But, if your Active Directory has a Global Directory configured, typically on port 3268, then you might be able to get the query you need to work:

AuthLDAPURL "ldap://eiadserver1.einstruction.com:3268/DC=einstruction,DC=com?sAMAccountName?sub?(objectClass=user)"

"

I checked our AD server and it's listening on port 3268, so I changed it, it did fix the problem.

jack.chen.job
  • 123
  • 2
  • 6
  • 1
    Welcome to Server Fault! While this may theoretically answer the question, [it would be preferable to include the essential parts of the answer here](http://meta.stackexchange.com/questions/8231/are-answers-that-just-contain-links-elsewhere-really-good-answers/8259#8259), and provide the link for reference. – HopelessN00b Jan 22 '14 at 20:52
  • The problem with this, is that it gives access to all Active Directory users, I need a solution where I can give access to only certain PO. – Eran Chetzroni Jan 29 '14 at 07:41