Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I have installed Apache Subversion on my linux server under /var/svn

Currently we are doing two projects in our company with 2 groups:

  • The first group is using the Subversion under:

https://www.lumiin.ch/svn/lumin/trunk

  • The second group is using the Subversion under:

https://www.lumiin.ch/svn/lumin/trunk/mindmade/html5

Now the problem is the second group is able to read / write the code from the first group link.

Now i want to restrict the second group user from the first group link. They should not able to read / write the code.

How to deny authorization for second group users for the path?

Can any help me out in this?

Regards Karthick

share|improve this question
    
BTW it's called 'authorization' (it's about access rights) not 'authentication' (this one is about user's identity check). See the difference: en.wikipedia.org/wiki/Authorization and en.wikipedia.org/wiki/Authentication –  bahrep Aug 6 '12 at 10:29

2 Answers 2

I assume you serve your SVN via apache2 using the SVNPath directive.

First add there authentication requirement to httpd.conf file:

<Location /svn>
  DAV svn
  SVNPath /mnt/big/svn
  AuthType Basic
  AuthName "SVN Server"
  # create svn.pass using htpasswd
  AuthUserFile /etc/apache2/svn.pass
  Require valid-user
</Location>

Then add in the Location section AuthzSVNAccessFile directive pointing to file that will define permissions, e.g.:

[groups]
group1=martin,jane,bob
group2=jane,james,johan

[/]
* = r

[/project1]
* =
@group1 = rw

[/project1]
* =
@group2 = rw

You can find much more info eg in the version control with subversion - especially here.

share|improve this answer
    
Thanks for ur reply.. –  Karthick88it Aug 8 '12 at 7:25

I see the other issue, the fundamental one, if I can call it so. It's not about authorization (pQd's answer pretty much covers the authorization topic).

Why did you organize your repository this way?

You have 2 groups working on different projects but the projects are placed under main branch 'trunk'.

Why don't you use separate branches for separate groups of users or for separate projects?

For me it looks like your repository is poorly organized (as far as I see and understand). You should definitely consider the SVNBook article: "Strategies for Repository Deployment".

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.