aboutsummaryrefslogblamecommitdiffstats
path: root/vendor/sabre/dav/docs/caldav-proxy.txt
blob: 2d96bfc82eb93d4ceb84b16b5bf3f739ac972b81 (plain) (tree)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560















































































































































































































































































































































































































































































































































































                                                                        
Calendar Server Extension                                       C. Daboo
                                                          Apple Computer
                                                             May 3, 2007


              Calendar User Proxy Functionality in CalDAV
                           caldav-cu-proxy-02

Abstract

   This specification defines an extension to CalDAV that makes it easy
   for clients to setup and manage calendar user proxies, using the
   WebDAV Access Control List extension as a basis.


Table of Contents

   1.  Introduction . . . . . . . . . . . . . . . . . . . . . . . . .  2
   2.  Conventions Used in This Document  . . . . . . . . . . . . . .  2
   3.  Overview . . . . . . . . . . . . . . . . . . . . . . . . . . .  3
     3.1.  Server . . . . . . . . . . . . . . . . . . . . . . . . . .  3
     3.2.  Client . . . . . . . . . . . . . . . . . . . . . . . . . .  3
   4.  Open Issues  . . . . . . . . . . . . . . . . . . . . . . . . .  4
   5.  New features in CalDAV . . . . . . . . . . . . . . . . . . . .  4
     5.1.  Proxy Principal Resource . . . . . . . . . . . . . . . . .  4
     5.2.  Privilege Provisioning . . . . . . . . . . . . . . . . . .  8
   6.  Security Considerations  . . . . . . . . . . . . . . . . . . .  9
   7.  IANA Considerations  . . . . . . . . . . . . . . . . . . . . .  9
   8.  Normative References . . . . . . . . . . . . . . . . . . . . .  9
   Appendix A.  Acknowledgments . . . . . . . . . . . . . . . . . . .  9
   Appendix B.  Change History  . . . . . . . . . . . . . . . . . . . 10
   Author's Address . . . . . . . . . . . . . . . . . . . . . . . . . 10



















Daboo                                                           [Page 1]

                              CalDAV Proxy                      May 2007


1.  Introduction

   CalDAV [RFC4791] provides a way for calendar users to store calendar
   data and exchange this data via scheduling operations.  Based on the
   WebDAV protocol [RFC2518], it also includes the ability to manage
   access to calendar data via the WebDAV ACL extension [RFC3744].

   It is often common for a calendar user to delegate some form of
   responsibility for their calendar and schedules to another calendar
   user (e.g., a boss allows an assistant to check a calendar or to send
   and accept scheduling invites on his behalf).  The user handling the
   calendar data on behalf of someone else is often referred to as a
   "calendar user proxy".

   Whilst CalDAV does have fine-grained access control features that can
   be used to setup complex sharing and management of calendars, often
   the proxy behavior required is an "all-or-nothing" approach - i.e.
   the proxy has access to all the calendars or to no calendars (in
   which case they are of course not a proxy).  So a simple way to
   manage access to an entire set of calendars and scheduling ability
   would be handy.

   In addition, calendar user agents will often want to display to a
   user who has proxy access to their calendars, or to whom they are
   acting as a proxy.  Again, CalDAV's access control discovery and
   report features can be used to do that, but with fine-grained control
   that exists, it can be hard to tell who is a "real" proxy as opposed
   to someone just granted rights to some subset of calendars.  Again, a
   simple way to discover proxy information would be handy.


2.  Conventions Used in This Document

   The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
   "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this
   document are to be interpreted as described in [RFC2119].

   When XML element types in the namespace "DAV:" are referenced in this
   document outside of the context of an XML fragment, the string "DAV:"
   will be prefixed to the element type names.

   When XML element types in the namespaces "DAV:" and
   "urn:ietf:params:xml:ns:caldav" are referenced in this document
   outside of the context of an XML fragment, the string "DAV:" and
   "CALDAV:" will be prefixed to the element type names respectively.

   The namespace "http://calendarserver.org/ns/" is used for XML
   elements defined in this specification.  When XML element types in



Daboo                                                           [Page 2]

                              CalDAV Proxy                      May 2007


   this namespace are referenced in this document outside of the context
   of an XML fragment, the string "CS:" will be prefixed to the element
   type names respectively.


3.  Overview

3.1.  Server

   For each calendar user principal on the server, the server will
   generate two group principals - "proxy groups".  One is used to hold
   the list of principals who have read-only proxy access to the main
   principal's calendars, the other holds the list of principals who
   have read-write and scheduling proxy access.  NB these new group
   principals would have no equivalent in Open Directory.

   Privileges on each "proxy group" principal will be set so that the
   "owner" has the ability to change property values.

   The "proxy group" principals will be child resources of the user
   principal resource with specific resource types and thus are easy to
   discover.  As a result the user principal resources will also be
   collection resources.

   When provisioning the calendar user home collection, the server will:

   a.  Add an ACE to the calendar home collection giving the read-only
       "proxy group" inheritable read access.

   b.  Add an ACE to the calendar home collection giving the read-write
       "proxy group" inheritable read-write access.

   c.  Add an ACE to each of the calendar Inbox and Outbox collections
       giving the CALDAV:schedule privilege
       [I-D.desruisseaux-caldav-sched] to the read-write "proxy group".

3.2.  Client

   A client can see who the proxies are for the current principal by
   examining the principal resource for the two "proxy group" properties
   and then looking at the DAV:group-member-set property of each.

   The client can edit the list of proxies for the current principal by
   editing the DAV:group-member-set property on the relevant "proxy
   group" principal resource.

   The client can find out who the current principal is a proxy for by
   running a DAV:principal-match REPORT on the principal collection.



Daboo                                                           [Page 3]

                              CalDAV Proxy                      May 2007


   Alternatively, the client can find out who the current principal is a
   proxy for by examining the DAV:group-membership property on the
   current principal resource looking for membership in other users'
   "proxy groups".


4.  Open Issues

   1.  Do we want to separate read-write access to calendars vs the
       ability to schedule as a proxy?

   2.  We may want to restrict changing properties on the proxy group
       collections to just the DAV:group-member-set property?

   3.  There is no way for a proxy to be able to manage the list of
       proxies.  We could allow the main calendar user DAV:write-acl on
       their "proxy group" principals, in which case they could grant
       others the right to modify the group membership.

   4.  Should the "proxy group" principals also be collections given
       that the regular principal resources will be?


5.  New features in CalDAV

5.1.  Proxy Principal Resource

   Each "regular" principal resource that needs to allow calendar user
   proxy support MUST be a collection resource. i.e. in addition to
   including the DAV:principal XML element in the DAV:resourcetype
   property on the resource, it MUST also include the DAV:collection XML
   element.

   Each "regular" principal resource MUST contain two child resources
   with names "calendar-proxy-read" and "calendar-proxy-write" (note
   that these are only suggested names - the server could choose any
   unique name for these).  These resources are themselves principal
   resources that are groups contain the list of principals for calendar
   users who can act as a read-only or read-write proxy respectively.

   The server MUST include the CS:calendar-proxy-read or CS:calendar-
   proxy-write XML elements in the DAV:resourcetype property of the
   child resources, respectively.  This allows clients to discover the
   "proxy group" principals by using a PROPFIND, Depth:1 request on the
   current user's principal resource and requesting the DAV:resourcetype
   property be returned.  The element type declarations are:





Daboo                                                           [Page 4]

                              CalDAV Proxy                      May 2007


   <!ELEMENT calendar-proxy-read EMPTY>

   <!ELEMENT calendar-proxy-write EMPTY>

   The server MUST allow the "parent" principal to change the DAV:group-
   member-set property on each of the "child" "proxy group" principal
   resources.  When a principal is listed as a member of the "child"
   resource, the server MUST include the "child" resource URI in the
   DAV:group-membership property on the included principal resource.
   Note that this is just "normal" behavior for a group principal.

   An example principal resource layout might be:

           + /
             + principals/
               + users/
                 + cyrus/
                     calendar-proxy-read
                     calendar-proxy-write
                 + red/
                     calendar-proxy-read
                     calendar-proxy-write
                 + wilfredo/
                     calendar-proxy-read
                     calendar-proxy-write

   If the principal "cyrus" wishes to have the principal "red" act as a
   calendar user proxy on his behalf and have the ability to change
   items on his calendar or schedule meetings on his behalf, then he
   would add the principal resource URI for "red" to the DAV:group-
   member-set property of the principal resource /principals/users/
   cyrus/calendar-proxy-write, giving:

   <DAV:group-member-set>
     <DAV:href>/principals/users/red/</DAV:href>
   </DAV:group-member-set>

   The DAV:group-membership property on the resource /principals/users/
   red/ would be:

   <DAV:group-membership>
     <DAV:href>/principals/users/cyrus/calendar-proxy-write</DAV:href>
   </DAV:group-membership>

   If the principal "red" was also a read-only proxy for the principal
   "wilfredo", then the DA:group-membership property on the resource
   /principals/users/red/ would be:




Daboo                                                           [Page 5]

                              CalDAV Proxy                      May 2007


   <DAV:group-membership>
     <DAV:href>/principals/users/cyrus/calendar-proxy-write</DAV:href>
     <DAV:href>/principals/users/wilfredo/calendar-proxy-read</DAV:href>
   </DAV:group-membership>

   Thus a client can discover to which principals a particular principal
   is acting as a calendar user proxy for by examining the DAV:group-
   membership property.

   An alternative to discovering which principals a user can proxy as is
   to use the WebDAV ACL principal-match report, targeted at the
   principal collections available on the server.

   Example:

   >> Request <<

   REPORT /principals/ HTTP/1.1
   Host: cal.example.com
   Depth: 0
   Content-Type: application/xml; charset="utf-8"
   Content-Length: xxxx
   Authorization: Digest username="red",
    realm="cal.example.com", nonce="...",
    uri="/principals/", response="...", opaque="..."

   <?xml version="1.0" encoding="utf-8" ?>
   <D:principal-match xmlns:D="DAV:">
     <D:self/>
     <D:prop>
       <D:resourcetype/>
     </D:prop>
   </D:principal-match>


















Daboo                                                           [Page 6]

                              CalDAV Proxy                      May 2007


   >> Response <<

   HTTP/1.1 207 Multi-Status
   Date: Fri, 10 Nov 2006 09:32:12 GMT
   Content-Type: application/xml; charset="utf-8"
   Content-Length: xxxx

   <?xml version="1.0" encoding="utf-8" ?>
   <D:multistatus xmlns:D="DAV:"
                  xmlns:A="http://calendarserver.org/ns/">
     <D:response>
       <D:href>/principals/users/red/</D:href>
       <D:propstat>
         <D:prop>
           <D:resourcetype>
             <D:principal/>
             <D:collection/>
           </D:resourcetype>
         </D:prop>
         <D:status>HTTP/1.1 200 OK</D:status>
       </D:propstat>
     </D:response>
     <D:response>
       <D:href>/principals/users/cyrus/calendar-proxy-write</D:href>
       <D:propstat>
         <D:prop>
           <D:resourcetype>
             <D:principal/>
             <A:calendar-proxy-write/>
           </D:resourcetype>
         </D:prop>
         <D:status>HTTP/1.1 200 OK</D:status>
       </D:propstat>
     </D:response>
     <D:response>
       <D:href>/principals/users/wilfredo/calendar-proxy-read</D:href>
       <D:propstat>
         <D:prop>
           <D:resourcetype>
             <D:principal/>
             <A:calendar-proxy-read/>
           </D:resourcetype>
         </D:prop>
         <D:status>HTTP/1.1 200 OK</D:status>
       </D:propstat>
     </D:response>
   </D:multistatus>




Daboo                                                           [Page 7]

                              CalDAV Proxy                      May 2007


5.2.  Privilege Provisioning

   In order for a calendar user proxy to be able to access the calendars
   of the user they are proxying for the server MUST ensure that the
   privileges on the relevant calendars are setup accordingly:

      The DAV:read privilege MUST be granted for read-only and read-
      write calendar user proxy principals

      The DAV:write privilege MUST be granted for read-write calendar
      user proxy principals.

   Additionally, the CalDAV scheduling Inbox and Outbox calendar
   collections for the user allowing proxy access, MUST have the CALDAV:
   schedule privilege [I-D.desruisseaux-caldav-sched] granted for read-
   write calendar user proxy principals.

   Note that with a suitable repository layout, a server may be able to
   grant the appropriate privileges on a parent collection and ensure
   that all the contained collections and resources inherit that.  For
   example, given the following repository layout:

           + /
             + calendars/
               + users/
                 + cyrus/
                     inbox
                     outbox
                     home
                     work
                 + red/
                     inbox
                     outbox
                     work
                     soccer
                 + wilfredo/
                     inbox
                     outbox
                     home
                     work
                     flying

   In order for the principal "red" to act as a read-write proxy for the
   principal "cyrus", the following WebDAV ACE will need to be granted
   on the resource /calendars/users/cyrus/ and all children of that
   resource:





Daboo                                                           [Page 8]

                              CalDAV Proxy                      May 2007


   <DAV:ace>
     <DAV:principal>
       <DAV:href>/principals/users/cyrus/calendar-proxy-write</DAV:href>
     </DAV:principal>
     <DAV:privileges>
       <DAV:grant><DAV:read/><DAV:write/></DAV:grant>
     </DAV:privileges>
   </DAV:ace>


6.  Security Considerations

   TBD


7.  IANA Considerations

   This document does not require any actions on the part of IANA.


8.  Normative References

   [I-D.desruisseaux-caldav-sched]
              Desruisseaux, B., "Scheduling Extensions to CalDAV",
              draft-desruisseaux-caldav-sched-03 (work in progress),
              January 2007.

   [RFC2119]  Bradner, S., "Key words for use in RFCs to Indicate
              Requirement Levels", BCP 14, RFC 2119, March 1997.

   [RFC2518]  Goland, Y., Whitehead, E., Faizi, A., Carter, S., and D.
              Jensen, "HTTP Extensions for Distributed Authoring --
              WEBDAV", RFC 2518, February 1999.

   [RFC3744]  Clemm, G., Reschke, J., Sedlar, E., and J. Whitehead, "Web
              Distributed Authoring and Versioning (WebDAV) Access
              Control Protocol", RFC 3744, May 2004.

   [RFC4791]  Daboo, C., Desruisseaux, B., and L. Dusseault,
              "Calendaring Extensions to WebDAV (CalDAV)", RFC 4791,
              March 2007.


Appendix A.  Acknowledgments

   This specification is the result of discussions between the Apple
   calendar server and client teams.




Daboo                                                           [Page 9]

                              CalDAV Proxy                      May 2007


Appendix B.  Change History

   Changes from -00:

   1.  Updated to RFC 4791 reference.

   Changes from -00:

   1.  Added more details on actual CalDAV protocol changes.

   2.  Changed namespace from http://apple.com/ns/calendarserver/ to
       http://calendarserver.org/ns/.

   3.  Made "proxy group" principals child resources of their "owner"
       principals.

   4.  The "proxy group" principals now have their own resourcetype.


Author's Address

   Cyrus Daboo
   Apple Computer, Inc.
   1 Infinite Loop
   Cupertino, CA  95014
   USA

   Email: cyrus@daboo.name
   URI:   http://www.apple.com/






















Daboo                                                          [Page 10]