Using LDAP to authorize svn

by @im_a_muppet on January 29, 2008

This will allow you to specify users in the ldap directory that can be svn authors. They do not need to exist on any server just in LDAP. Apache will test the user login versus the ldap credentials and then grant access to the repository for that user.

with

      hosting server = ldap.willspics.com
      repository location on server = /opt/svnserve/repos
      repository location on web = http://<server>/svn/repos

edit /etc/httpd/conf.d/subversion.conf to contain the following

<Location /svn/repos>
  DAV svn
  SVNPath /opt/svnserve/repos
  AuthType Basic
  AuthName "Authorize Me"
  AuthLDAPEnabled on
  AuthLDAPAuthoritative on
  AuthLDAPBindDN "CN=Manager,DC=epl,DC=willspics,DC=com"
  AuthLDAPBindPassword xxxxxxxxx
  Options Indexes FollowSymLinks
  AuthLDAPURL ldap://ldap.xxxserver.com:389/ou=people,dc=epl,dc=xxxserver,dc=com?uid?sub?(objectClass=*)
  Require valid-user
</Location>
blog comments powered by Disqus
Tweet