title: svn ldap automatic authorisation
body: <p>When we decided to move to LDAP auth for SVN I had assumed that authentication &amp; authorisation would be automatic, i.e. if a user is logged into the network, subversion would accept the user as legitimate and not pop up a login dialog, but just get on with life. Unfortunately, so far we have not achieved this.</p>
  
  <p>It causes problems with, amongst other things, my Source Control extranet web application which used to do a user password lookup (not secure) but now must request authorisation.</p>
  
  <p>Should SVN/LDAP work like I had hoped? If so, is there some arcane config item I need to set? What am I missing?</p>
  
  <p>This, I think, is the appropriate .conf [redacted and obfuscated, of course]
  <div class="snippet" data-lang="js" data-hide="false">
  <div class="snippet-code">
  <pre class="snippet-code-html lang-html prettyprint-override"><code>#
  #
  # DO NOT EDIT THIS FILE IT WILL BE REGENERATED AUTOMATICALLY BY SUBVERSION EDGE
  #
  # If you must make a change to the contents of this file then copy and paste the
  # content into the httpd.conf file and comment out the Include statement for
  # this file. The httpd.conf file is not modified or generated and is safe for
  # you to modify.
  #
  #
  
  Include "F:\csvn\data/conf/ctf_httpd.conf"
  &lt;VirtualHost *:18080&gt;
  # SSL is off
  
  # Required for SCRIPT_URI/URL in viewvc libs, not just rewrite rules
  RewriteEngine on
  RewriteOptions inherit
  
  # Apache will issue sub_req for PATH_INFO on ScriptAlias which
  # gives a spurious error message. Setting auth at root level to avoid clogging logs.
  &lt;Location /&gt;
    AuthType Basic
    AuthName "CollabNet Subversion Repository"
    AuthBasicProvider file ldap
    AuthLDAPUrl "ldap://192.168.0.249:3268/OU=Technical Staff,OU=DomainUsers,DC=snip,DC=net?samAccountName?sub" "NONE"
  
    AuthLDAPBindDN "CN=subversion,OU=Technical Staff,OU=DomainUsers,DC=snip,DC=net"
    AuthLDAPBindPassword "kasd8asdik"
    LDAPReferrals Off
  
  
    AuthUserFile "F:\csvn\data/conf/svn_auth_file"
  
    Require valid-user
  &lt;/Location&gt;
  
  # Work around authz and SVNListParentPath issue
  RedirectMatch ^(/svn)$ $1/
  &lt;Location /svn/&gt;   
     DAV svn
     SVNParentPath "F:/csvn/data/repositories"
     SVNReposName "CollabNet Subversion Repository"
  
    &lt;IfModule deflate_module&gt;
      SetOutputFilter DEFLATE
    &lt;/IfModule&gt;
    AuthzSVNAccessFile "F:\csvn\data/conf/svn_access_file"
    SVNPathAuthz short_circuit
    SVNListParentPath On
  &lt;/Location&gt;
  
  
  &lt;Directory "F:\csvn\www\viewVC/docroot"&gt;
    AllowOverride None
    Options None
  &lt;/Directory&gt;
  &lt;Location /viewvc-static&gt;
    Require all granted
  &lt;/Location&gt;
  Alias /viewvc-static "F:\csvn\www\viewVC/docroot"
  
  ScriptAlias /viewvc "F:\csvn\bin/cgi-bin/viewvc.cgi"
  
  &lt;Location /viewvc&gt;
    AddDefaultCharset UTF-8
    SetEnv CSVN_HOME "F:\csvn"
  &lt;/Location&gt;
  
  &lt;/VirtualHost&gt;
  
  #
  # auth helper endpoint for use by SvnEdge
  #        
  &lt;VirtualHost localhost:50123&gt;
    &lt;Location "/"&gt;
    AuthType Basic
    AuthName "CollabNet Subversion Repository"
    AuthBasicProvider file ldap
    AuthLDAPUrl "ldap://192.168.0.249:3268/OU=Technical Staff,OU=DomainUsers,DC=snip,DC=net?samAccountName?sub" "NONE"
  
    AuthLDAPBindDN "CN=subversion,OU=Technical Staff,OU=DomainUsers,DC=snip,DC=net"
    AuthLDAPBindPassword "kasd8asdik"
    LDAPReferrals Off
  
  
    AuthUserFile "F:\csvn\data/conf/svn_auth_file"
  
  
    Require valid-user
    &lt;/Location&gt;
  &lt;/VirtualHost&gt;</code></pre>
  </div>
  </div>
  </p>