LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 08-25-2016, 06:23 AM   #1
Poison Nuke
Member
 
Registered: Aug 2012
Location: Germany
Posts: 41

Rep: Reputation: Disabled
apache require ldap-group : authorization failed for all but first user


Hello,

I have problems with ldap and apache. I have an openLDAP backend (slapd) managed from phpldapadmin and a very simple groups/users setup.

dc=fritz,dc=box
cn=ldapreader
-ou=groups
-cn=sysops
ou=users
-cn=foo
-cn=bar

both users are member of sysops (gid and memberUid)


In my virtual host configuration of apache I have the following statements:

Code:
                AuthName "test"
                AuthType Basic
                AuthBasicProvider ldap

                #ldap user who can read database
                AuthLDAPBindDN "cn=ldapreader,dc=fritz,dc=box"
                AuthLDAPBindPassword "pass"
                AuthLDAPUrl "ldap://localhost/ou=users,dc=fritz,dc=box?uid"
                AuthLDAPGroupAttribute memberUid
                AuthLDAPGroupAttributeIsDN off

                Require ldap-group cn=sysops,ou=groups,dc=fritz,dc=box
I can login as foo
but I cannot login as bar
(and any subsequent created users)

If I change Require to "valid-users" I can login with both users. So it is releated to require ldap-group.


any suggestions?
 
Old 09-06-2016, 11:38 AM   #2
mpapet
Member
 
Registered: Nov 2003
Location: Los Angeles
Distribution: debian
Posts: 548

Rep: Reputation: 72
My first guess is there is only one user in your LDAP sysops group. My second guess is there is something wrong with user bar.

You need to see if you can replicate the problem using ldapsearch on the command line. Here are a couple of examples: https://access.redhat.com/documentat...psearches.html phpadmin is not a great way to manage an ldap server. (Cue angry replies... Yeah, not going back.)

I use jxplorer as a gui. http://jxplorer.org/
 
Old 09-06-2016, 11:47 AM   #3
Poison Nuke
Member
 
Registered: Aug 2012
Location: Germany
Posts: 41

Original Poster
Rep: Reputation: Disabled
thanks. Almost forgot this thread.

Ive made an interesting obseveration so far: If i change Require to "valid-user", reload apache, log in successfull, restore old configuration and reload again and login again, then it works like expected even with newly created users in sysops.

Looks like the communication between slapd and apache stucks after the first configuration attempt of apache (my guess).

At this time, there a no more problems. I will have a look on this issue when I create a new virtual host with ldap.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Apache authentication: allow LDAP group OR user named guest, but not all LDAP users AlucardZero Linux - Server 1 05-25-2011 03:21 PM
Apache Auth: Using Require User and Require Group newmanium2001 Linux - Software 1 08-25-2009 02:39 PM
apache active directory require group.. zerocool22 Linux - Server 0 05-06-2008 03:38 AM
Apache2 Require user with Require group Russianspi Linux - Server 2 01-30-2008 11:21 AM
LXer: Apache authentication and authorization using LDAP LXer Syndicated Linux News 0 10-31-2007 03:50 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 05:56 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration