LinuxQuestions.org
View the Most Wanted LQ Wiki articles.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices

Reply
 
LinkBack Search this Thread
Old 10-19-2007, 10:49 AM   #1
laggerific
Member
 
Registered: Jan 2006
Posts: 65

Rep: Reputation: 15
Question apache ldap authentication with htpasswd


I'm running Apache 2.0 and am attempting to use LDAP authentication along with htpasswd authentication. For some reason on my dev area it appears to be working okay, but on my production instance this same stuff is messed up.

Here is the conf.d file for the location:

<Location /svn>
DAV svn
SVNParentPath /svnroot
# Require SSL connection for password protection.
# SSLRequireSSL
AuthLDAPAuthoritative off
AuthUserFile /svn-auth-file
AuthType Basic
AuthName "SVN"
AuthLDAPBindDN "LDAPbindinfo"
AuthLDAPBindPassword "password"
AuthLDAPURL "url"
Require valid-user
</Location>

When I try to do an LDAP auth I get the following error:

[Fri Oct 19 08:27:29 2007] [error] [client x.x.x.x] user xxxxxx not found: /svn

It's as if it is completely ignoring the LDAP authentication. I know that LDAP is working, because if I comment out the "AuthUserFile" statement ldap works, but if I have it in there, only auth against the htpasswd file is functional, and I don't see any errors related to LDAP auth, just that it can't file the user in the directory. I don't see any differences between the httpd.conf between the two systems either.

Any ideas what might be happening here?

Thank you!
 
Old 10-26-2007, 11:36 AM   #2
laggerific
Member
 
Registered: Jan 2006
Posts: 65

Original Poster
Rep: Reputation: 15
Just giving this issue a bump, as I now have time to continue researching this issue...hoping someone else might have some insights into this sort of behavior.

Any reason why the same config would be working in the dev env. but not in the prod env.?
 
Old 10-26-2007, 01:03 PM   #3
laggerific
Member
 
Registered: Jan 2006
Posts: 65

Original Poster
Rep: Reputation: 15
I literally copied the httpd.conf and the conf.d conf file used on the prod system to dev, and it worked fine.

It's not like LDAP doesn't work on the prod system, it really seems like it should be a configuration issue, yet I don't see how with the test I just did.
 
Old 01-07-2010, 08:37 AM   #4
carters2
LQ Newbie
 
Registered: Sep 2009
Posts: 20

Rep: Reputation: 1
Did you ever come up with a solution for this? I have been trying to do the same thing with no success

EDIT:

I realize this is a stale post but here is the solution

<Location /svn/ngoerepos>
DAV svn
SVNPath /apps/svn/ngoerepos

#GENERAL CONFIG
AuthName "NGOE Subversion LDAP & HTPASSWD"
#AuthzSVNAccessFile /etc/httpd/conf/svn/access_file
AuthType Basic

#LDAP AUTHENICATION
AuthzLDAPServer ldapserver.mydomain.com
AuthzLDAPUserBase "OU=Users,DC=mydomain,DC=com"
AuthzLDAPBindDN "CN=svn_user,OU=UsersDC=mydomain,DC=com"
AuthzLDAPBindPassword "4UfaxAsp"
AuthzLDAPUserKey sAMAccountName
AuthzLDAPUserScope subtree
AuthzLDAPMethod ldap
AuthzLDAPAuthoritative off

#HTPASSWD AUTHENTICATION
AuthUserFile /etc/httpd/conf/svn/svn_user_file
AuthBasicAuthoritative off

Require valid-user
</Location>

This allows you to either authenticate with ldap or htpasswd. They key directives are in red

Last edited by carters2; 01-07-2010 at 09:20 AM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Apache LDAP authentication Amuro-Ray2020 Linux - Security 5 07-28-2007 06:31 PM
ldap authentication for Apache anjani.78 Linux - Software 1 08-03-2006 04:06 AM
Apache: htpasswd error daedalus703 Linux - Software 1 04-03-2006 12:03 AM
[apache] disable htpasswd in subtrees? yapp Linux - Networking 4 01-13-2005 11:22 PM
Apache .htpasswd use windows authentication? meeshka Linux - Networking 1 07-14-2003 10:14 PM


All times are GMT -5. The time now is 07:48 AM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration