No announcement yet.

svn not prompting while access svn repo

  • Filter
  • Time
  • Show
Clear All
new posts

  • svn not prompting while access svn repo

    I have installed svn 1.9.4(apache subversion) in fedora 23 follow this link https://www.if-not-true-then-false.c...-red-hat-rhel/

    After Create and configure SVN repository, Restart the service then go to browser. http://localhost/svn/repo its not prompt to ask user name and password its goes
    directly repo files with out username and password.

    These are my Configuration :


    LoadModule dav_svn_module modules/
    LoadModule authz_svn_module modules/
    LoadModule dontdothat_module modules/

    <Location /svn>
    DAV svn
    SVNParentPath /var/www/svn

    # Limit write permission to list of valid users.
    # Require SSL connection for password protection.
    # SSLRequireSSL

    AuthType Basic
    AuthName "Subversion repositories"
    AuthUserFile /etc/svn-auth-users
    Require valid-user


    anon-access = none
    auth-access = write
    password-db = passwd
    authz-db = authz


    harry = harryssecret
    sally = sallyssecret

    Suggest me What's Wrong in my Configuration and how to fix this.

  • #2
    What's in your "svnserve.conf" file is immaterial when your access is going through Apache.

    So your Apache config file needs to specify more stuff. Here's an example of what I mean:

    <Location /svn>
    DAV svn
    SVNParentPath /var/www/svn
    AuthName "Subversion repositories"
    AuthType Basic
    AuthBasicProvider file
    AuthUserFile /etc/svn-auth-users
    Require valid-user
    AuthzSVNAccessFile /opt/repo/ApacheAuthZ.conf

    The "ApacheAuthZ.conf" file is the same format as the svnserve.conf's "authz-db" specified file but the section headers should have the repository name in them:

    harry = r
    sally = rw

    harry = rw
    sally = r

    See here:

    NOTE WELL: I strongly recommend against using the "Limit" mechanisms since they are simply going to get you in trouble. They take an SVN *expert* to truly get right. I have seen their usage completely out of control without providing the appropriate restrictions, permissions, etc. For instance, there is a huge difference between the SVN 1 ( and SVN 2 ( webdav protocols and that impacts what is needed for the "Limit" mechanisms.


    • #3
      DougR, much obliged for that note about "Limit" in the Apache configuration. I had a new Subversion repository all set up, httpd all set up, htpassword accounts all set up, authz all set up, the SELinux contexts and context types etc were all good to go...and I couldn't log in from anything to save my life. Nothing was even asking for credentials. The Apache error_log unfortunately was not illuminating, precisely because it was the result of adding a <LimitExcept>. The only thing that saved me was reading your response here.

      Once I finish setting up my new home dev environment (the usual routine after getting new kit) I'll probably learn up on why the <LimitExcept> caused such a blocker. More out of curiosity than because it's important. Thanks again.


      • #4
        Glad that it helped! Cheers.


        • #5
          I'm having a similar issue here:

          * OS: CentOS Linux release 7.6.1810 (Core)
          * Apache: 2.4.6
          * Subversion: 1.9.9-1
          * Apache config file:
          LoadModule dav_svn_module     modules/
          LoadModule authz_svn_module   modules/
          <Location /svn>
              DAV svn
              SVNParentPath /opt/svn
              AuthType Basic
              AuthName "SVN Repos"
              AuthUserFile /etc/htpasswd
              AuthzSVNAccessFile /opt/svn/conf/authz
              Require valid-user
          I don't see any related messages in apache or system logs, but I can't get the browser to ask for the password and the repository contents is displayed without any user authentificacion. I can't figure out what's wrong with my configuration ...


          Last edited by palevi; 06-17-2019, 04:57 PM.


          • #6
            Turn off SELinux if you find it on. Requires a reboot.

            Make sure that all path components (e.g. "/", "/opt", "/opt/svn", "/opt/svn/reponame") are properly owned, grouped and permissioned.

            Make sure that your "/var/log/httpd" directory is properly protected, etc.

            If you're not starting Apache as "root" then it won't be able to log into the normal location so you'll need to choose paths for logs, etc. that work. And you're going to need to use a port > 1024.


            • #7

              I set SELinux to permissive:

              sudo setenforce Permissive
              and it started to prompt for password as expected. Aha, an SELinux issue!. Just to make sure, I set SELinux to enforcing and test if it fails again ...

              sudo setenforce Enforcing
              but it keeps prompting for password! I rebooted, and it keeps working ...

              I don't understand what has happened here, but now I get my system working as expected, thanks a lot for pointing me in the right direction ...

              Last edited by palevi; 06-18-2019, 08:39 AM.


              • #8
                That's strange. I hope it keeps on working. Cheers.