Mailing List Archive

the correct Use/syntax of default_privileges
Hi Devs!

i recently tried to learn about the "default_privileges" thing you
mentioned on several places on your website. However... it is nowhere
mentioned how to use this parameter correctly. Especialy when it comes
to an ORDER of the allowed keywords/permissions.

I read, that the permissions is a 24bit binary word where each bit is a
flag for a specific permission. so "usualy" the bitorder or possition of
a single bit is critical.

But what about that strange looking construct here:

$c->default_privileges = array('read-free-busy', 'schedule-deliver');

Is the apearance of the keywords of any importance ?

Also what keywords are allowed? The pages mentioning MULTIPLE VERSIONS
OF NAMES! So what version to use?

One time there is "read-free-busy" used, another time its called
"CALDAV:read-free-busy". WHO ELSE but a developer should know now what
to use?

So i ask for some clearance and some additional information on that
webpages. Thanks!

best regards
Axel
the correct Use/syntax of default_privileges [ In reply to ]
On Mon, 2011-01-31 at 13:53 +0100, Axel Werner wrote:
> Hi Devs!
>
> i recently tried to learn about the "default_privileges" thing you
> mentioned on several places on your website. However... it is nowhere
> mentioned how to use this parameter correctly. Especialy when it comes
> to an ORDER of the allowed keywords/permissions.
>
> I read, that the permissions is a 24bit binary word where each bit is a
> flag for a specific permission. so "usualy" the bitorder or possition of
> a single bit is critical.
>
> But what about that strange looking construct here:
>
> $c->default_privileges = array('read-free-busy', 'schedule-deliver');
>
> Is the apearance of the keywords of any importance ?
>
> Also what keywords are allowed? The pages mentioning MULTIPLE VERSIONS
> OF NAMES! So what version to use?
>
> One time there is "read-free-busy" used, another time its called
> "CALDAV:read-free-busy". WHO ELSE but a developer should know now what
> to use?
>
> So i ask for some clearance and some additional information on that
> webpages. Thanks!

No problem.

The code translates the part of the name following the colon into a
bitmask for each element of the array. These masks are then
bitwise-ORed to produce the full bitmask.

So:

* Order is unimportant.
* The part of the name before the ":" is also unimportant.

Cheers,
Andrew.
--
------------------------------------------------------------------------
andrew (AT) morphoss (DOT) com +64(272)DEBIAN
Building more free and open source software for New Zealanders
------------------------------------------------------------------------

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: This is a digitally signed message part
URL: <http://lists.davical.org/pipermail/davical-dev/attachments/20110201/00dcec65/attachment.pgp>