[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: Suggestion for user auth.: regex

From: Philip Martin <philip.martin_at_wandisco.com>
Date: Wed, 28 Mar 2012 10:21:36 +0100

Josef RIESENEDER <rieseneder_at_racon-linz.at> writes:

> I have an suggestion for checking the user access. It would be nice to use
> a regex in the path instead of the full path.
>
> Instead of this:
> [/currTree/trunk/config]
> @user = rw
> [/currTree/branches/branch1/config]
> @user = rw
>
> It should be possible to use simply a regex:
> [/currTree/.*/config]
> @user = rw

What happens with multiple matches? Can you define a consistent set of
rules that will allow people to predict the behaviour? Given:

[/foo/.*/bar]
@user = rw

[/foo/.*]
@user =

[/.*/bar]
@user = r

[/f.*/z.*/b.*]
@user = r

[/foo/zig/bar.*]
@user = rw

What access does @user have to /foo/zig/bar?

One possibility is that we get the union of all the matches; this has
similarities to

[/foo/zig/bar]
@users = r
@admin = rw

where a name that is present in @users and @admin gets r+rw=rw.

-- 
uberSVN: Apache Subversion Made Easy
http://www.uberSVN.com
Received on 2012-03-28 11:22:14 CEST

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.