6
votes

I am using viewvc(V1.1.22) along with svn (V1.8) and svn uses svnserve path based access. Viewvc works fine when the user has read access on the repository level. When the user doesn't have read access on the repository level, it throws an error like the below, even though I access the full url including the allowed path:

URL: https://mysvn.com/viewvc/test-repo/branches/branch-A/dist

The root "test-repo" is unknown. If you believe the value is correct, then please double-check your configuration.

HTTP Response Status

404 Not Found

My auth file looks like the below:

[groups]

test_group = user1, user2

[/] * =

[:glob:test-repo:/branches/*/dist]

@test_group = r

If I add one more rule giving read access to the repository level, viewvc works fine.

[test-repo:/]

@test_group = r

Is there any way to tell viewvc to allow browsing on allowed folders even though, the repository level access is restricted? Any help appreciated.

1

1 Answers

0
votes

The main issue between the two interfaces is that ViewVC requires that you give permissions from the top of the repository all the way down. WebSVN allows you to just give permissions in a subfolder and it gives limited implied permissions up to the top. To get around this you need to make two changes to the auth file.

  1. Give anonymous (star) read permissions at the root, so anyone can get to folders further down the tree that they need access to.
  2. Now, you need to remove permissions to all the subfolders you don't want them in.

For a detailed example including what exact changes you'd have to make to your auth file, see this link: ViewVC and SVN permissions