diff --git a/master.html b/master.html index 4ddc296f..549cb6a9 100644 --- a/master.html +++ b/master.html @@ -838,25 +838,27 @@ user2:password2 # Allow reading and writing principal collection (same as user name) [principal] user: .+ -collection: %(login)s +collection: {user} permissions: RW # Allow reading and writing calendars and address books that are direct # children of the principal collection [calendars] user: .+ -collection: %(login)s/[^/]+ +collection: {user}/[^/]+ permissions: rw
The titles of the sections are ignored (but must be unique). The keys user
and collection
contain regular expressions, that are matched against the user name and the path of the collection. Permissions from the first matching section are used. If no section matches, access gets denied.
The user name is empty for anonymous users. Therefore, the regex .+
only matches authenticated users and .*
matches everyone (including anonymous users).
The path of the collection is separated by /
and has no leading or trailing /
. Therefore, the path of the root collection is empty.
%(login)s
gets replaced by the user name and %(path)s
by the path of the collection. You can also use groups from the user
regex in the collection
regex with {1}
, {2}
, etc.
In the collection
regex you can use {user}
and get groups from the user
regex with {0}
, {1}
, etc.
In consequence of the parameter subsitution you have to write {{
and }}
if you want to use regular curly braces in the user
and collection
regexes.
The following permissions
are recognized: