2014-09-30 97 views
0

我测试SVN用户为只读访问只读用户:以下是是,我在的Apache2和svn回购conf下的配置:在颠覆

但是我的测试用户已经读取和写入权限,而不是我希望只读访问。

repo location 
/svn/test/ 

文件:/etc/apache2/conf.d/svn.conf

<location /repos> 
    DAV svn 
    #svn path 
    SVNParentPath /svn/ 
    AuthType Basic 
    AuthName "Authorization Realm" 
    #password file path 
    AuthUserFile /etc/subversion/test.users 
    Require valid-user 
</location> 

AuthZ的配置(只有一个条目) 文件:/ SVN /测试/ CONF/AuthZ的

[test:/svn/test/] 
* = r 

也试过:以下

[groups] 
readonly = user1, user2 

[/] 
*=r 
@readonly=r 

也试过:以下 [组] 只读=用户1,用户2

[10.29.3.238:80/repos/test] 
*=r 
+1

你的问题是什么? – 2014-09-30 16:43:36

回答

0

AuthzSVNAccessFile /svn/test/conf/authz

  • 您最后的authz文件格式错误:path-section 必须格式没有主机的URL或IP,只有[repository-name:/path/on/this/repo][/]是特例)。对于[test:/svn/test/],即在添加AuthzSVNAccessFile之后,将定义文件夹/ svn/test/in repository test作为所有人的RO,第二次尝试过多:* = r将为所有人定义所有存储库RO,@readonly = r还为另一个组(其为“Everybody” *