logo
Apache Lounge
Webmasters

 

About Forum Index Downloads Search Register Log in RSS X


Keep Server Online

If you find the Apache Lounge, the downloads and overall help useful, please express your satisfaction with a donation.

or

Bitcoin

A donation makes a contribution towards the costs, the time and effort that's going in this site and building.

Thank You! Steffen

Your donations will help to keep this site alive and well, and continuing building binaries. Apache Lounge is not sponsored.
Post new topic   Forum Index -> Apache View previous topic :: View next topic
Reply to topic   Topic: Query ldap server with apache2?
Author
chars



Joined: 14 Dec 2006
Posts: 11

PostPosted: Fri 15 Dec '06 1:13    Post subject: Query ldap server with apache2? Reply with quote

Hi,

I am working on a project to use ldap authentication with apache2 in Windows. The basic authentication worked fine, but for ldap, apache server will popup the authentication to ask the login name and password.
I have login name but there is no password for ldap. I got errors, when I checked the error.log. The error was:
auth_ldap authenticate: user authentication failed. Thank you to provide me a clue please and here is my ldap part of conf:
By the way, I don't have a .htaccess file for "the-dir/ldap-test" directory.

<Directory "the-dir/ldap-test">
SetHandler ldap-status
AuthName "LDAP Test"
AuthType Basic
AuthBasicProvider ldap
AuthzLDAPAuthoritative on
AuthLDAPURL ldap://ldap-server/base-dn?uid=jhon
require ldap-user jhon
</Directory>
Back to top
chars



Joined: 14 Dec 2006
Posts: 11

PostPosted: Sat 16 Dec '06 2:12    Post subject: I got the search/bind phase work but not the compare phase Reply with quote

I add a BindDN and password for the ldap conf part of httpd.conf, but have
error : [User not found][No Such Object]. Before this error was error of
[LDAP: ldap_simple_bind_s() failed] and that was a binding error.
I can view the ldap users with "ldap browser/editor" without a problem with anonymous bind. Can you tell what's wrong with my restrict bind
in my conf file please?

<Location /ldap-test/>
SetHandler ldap-status
AuthName "LDAP Test"
AuthType Basic
AuthBasicProvider ldap
AuthzLDAPAuthoritative on
AuthLDAPBindDN "cn=proxyAgent,ou=profile,dc=test,dc=com"
AuthLDAPPassword test1
AuthLDAPURL ldap://ldap-server/cn=proxyAgent,ou=profile,dc=test,dc=com?uid=jhon
require valid-user
</Location>
Back to top
chars



Joined: 14 Dec 2006
Posts: 11

PostPosted: Tue 19 Dec '06 2:02    Post subject: Got it passed Reply with quote

It is done with a help of my friend.
and AuthzLDAPAuthoritative should be off for
require valid-user
Back to top
Brian



Joined: 21 Oct 2005
Posts: 209
Location: Puyallup, WA USA

PostPosted: Tue 19 Dec '06 6:10    Post subject: Reply with quote

Pardon my ignorance, so I only ask because I do have interest in what you are discussing here. Is what you are doing is authenticating against an Active Directory user account?

Could you in general terms explain the scenerio. I find it very interesting the combintation of Windows and AD, along with Apache and web access specifically for corporate environments. I can imagine some very useful functions combining PHP, Perl, Python and Apache in a Windows Server environment.

Thanks.
Back to top
chars



Joined: 14 Dec 2006
Posts: 11

PostPosted: Tue 19 Dec '06 20:23    Post subject: Reply with quote

It is interested in working it through.

What I did is to use a LDAP server in UNIX as user directory service and link it with apache web server as ldap authentication.
You can use Active Directory to do the same thing too. Because the Active Directory is an implementation of LDAP directory services by Microsoft for use in Windows environments and it follows the fules of the ldap protocol.
Back to top
wmueller



Joined: 17 Jan 2007
Posts: 2

PostPosted: Thu 18 Jan '07 10:38    Post subject: Reply with quote

hallo

may i ask what apache version you use and what linux?

i try to do the same thing and have no success on it (apache2.0.x).

in my case i want to use ldap auth against an active directory to grant access to a svn repository. but i can imagine billions of use cases for this.

thanks Wink
Back to top


Reply to topic   Topic: Query ldap server with apache2? View previous topic :: View next topic
Post new topic   Forum Index -> Apache