Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

We're using Apache 2.2.12 to authenticate against one Active Directory domain using a .htaccess configuration file.

Our current configuration is:

AuthBasicProvider ldap
AuthType Basic
AuthName "AD LDAP Test"
AuthLDAPURL "ldap://192.168.0.10:389/OU=Users,DC=test,DC=site?sAMAccountName?sub"
AuthzLDAPAuthoritative On
AuthLDAPBindDN "administrator@test.site"
AuthLDAPBindPassword "Password"
require ldap-group CN=Sysadmins,OU=Users,DC=test,DC=site

We're encountering issues with authentication of users during access and authentication of the website.

[Sun Mar 16 13:26:25 2014] [warn] [client 192.168.0.10] [6740] auth_ldap authenticate: user rene authentication failed; URI / [ldap_search_ext_s() for user failed][No such object]
[Sun Mar 16 13:26:25 2014] [error] [client 192.168.0.10] user rene not found: /

The authentication of the AuthLDAPBindDN is working because if I change the password I receive

[Sun Mar 16 13:20:37 2014] [warn] [client 192.168.0.10] [6360] auth_ldap authenticate: user rene authentication failed; URI / [LDAP: ldap_simple_bind_s() failed][Invalid credentials]
[Sun Mar 16 13:20:37 2014] [error] [client 192.168.0.10] user rene: authentication failure for "/": Password Mismatch

during the authentication.

I verified the authentication with

ldapsearch -x -h 192.168.0.10 -LLL -b dc=test,dc=tc -D cn=rene,cn=Users,dc=test,dc=site -W "(cn=rene)" cn sAMAccountName

successful.

How can I configure Apache to correctly authenticate against the Active Directory?

share|improve this question

1 Answer 1

up vote 0 down vote accepted

In your test, you have:

cn=rene,cn=Users,dc=test,dc=site

In your configuration you have:

OU=Users,DC=test,DC=site

So... is Users a OU or a cn? Seems like this is your problem.

share|improve this answer
    
You are right. "Users" is a Active Directory build-in container and not a OU. To access it I have to use the CN. Thanks! –  Rene Mar 16 at 17:33

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.