-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdav-notifications.txt
616 lines (356 loc) · 18.7 KB
/
dav-notifications.txt
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
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
Network Working Group C. Daboo
Internet-Draft Apple Inc.
Expires: February 20, 2015 E. Pot
fruux GmbH
August 19, 2014
WebDAV: User Notifications
webdav-notifications-00
Abstract
This specification defines an extension to WebDAV that allows the
server to provide notifications to users.
Status of This Memo
This Internet-Draft is submitted in full conformance with the
provisions of BCP 78 and BCP 79.
Internet-Drafts are working documents of the Internet Engineering
Task Force (IETF). Note that other groups may also distribute
working documents as Internet-Drafts. The list of current Internet-
Drafts is at http://datatracker.ietf.org/drafts/current/.
Internet-Drafts are draft documents valid for a maximum of six months
and may be updated, replaced, or obsoleted by other documents at any
time. It is inappropriate to use Internet-Drafts as reference
material or to cite them other than as "work in progress."
This Internet-Draft will expire on February 20, 2015.
Copyright Notice
Copyright (c) 2014 IETF Trust and the persons identified as the
document authors. All rights reserved.
This document is subject to BCP 78 and the IETF Trust's Legal
Provisions Relating to IETF Documents
(http://trustee.ietf.org/license-info) in effect on the date of
publication of this document. Please review these documents
carefully, as they describe your rights and restrictions with respect
to this document. Code Components extracted from this document must
include Simplified BSD License text as described in Section 4.e of
the Trust Legal Provisions and are provided without warranty as
described in the Simplified BSD License.
Daboo & Pot Expires February 20, 2015 [Page 1]
Internet-Draft WebDAV User Notifications August 2014
Table of Contents
1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 2
2. Open Issues . . . . . . . . . . . . . . . . . . . . . . . . . 2
3. Conventions Used in This Document . . . . . . . . . . . . . . 3
4. Requirements Overview . . . . . . . . . . . . . . . . . . . . 3
5. Notifications . . . . . . . . . . . . . . . . . . . . . . . . 3
5.1. Mime type . . . . . . . . . . . . . . . . . . . . . . . . 4
5.2. Additional Principal Properties . . . . . . . . . . . . . 4
5.2.1. DAV:notification-URL Property . . . . . . . . . . . . 4
5.3. Properties on Notification Resources . . . . . . . . . . 5
5.3.1. DAV:notificationtype Property . . . . . . . . . . . . 5
5.4. XML Element Definitions . . . . . . . . . . . . . . . . . 6
5.4.1. DAV:notifications . . . . . . . . . . . . . . . . . . 6
5.4.2. DAV:notification . . . . . . . . . . . . . . . . . . 6
5.4.3. DAV:dtstamp . . . . . . . . . . . . . . . . . . . . . 6
6. Notification Definitions . . . . . . . . . . . . . . . . . . 7
6.1. System Status Notification . . . . . . . . . . . . . . . 7
6.1.1. DAV:systemstatus Element Definition . . . . . . . . . 7
7. Security Considerations . . . . . . . . . . . . . . . . . . . 8
8. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 8
9. Acknowledgments . . . . . . . . . . . . . . . . . . . . . . . 9
10. References . . . . . . . . . . . . . . . . . . . . . . . . . 9
10.1. Normative References . . . . . . . . . . . . . . . . . . 9
10.2. Informative References . . . . . . . . . . . . . . . . . 10
Appendix A. Backwards-compatibility with earlier drafts . . . . 10
Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 10
1. Introduction
It is often useful for servers to communicate arbitrary information
to the end-users for a WebDAV system, such as a system status,
message of the day or to notify users of changes that were made to
shared resources by other users.
This specification defines a generic "notification" mechanism that
allows a server to do that. Whilst primarily aimed at CalDAV
[RFC4791] and CardDAV [RFC6352] this mechanism has been designed to
be adaptable to other applications of WebDAV [RFC4918].
2. Open Issues
1. None?
Daboo & Pot Expires February 20, 2015 [Page 2]
Internet-Draft WebDAV User Notifications August 2014
3. 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 namespaces "DAV:" is referenced in this
document outside of the context of an XML fragment, the string "DAV:"
will be prefixed to the element type name.
4. Requirements Overview
To add support for WebDAV notifications, a server MUST at least have
support for WebDAV Class 3 [RFC4918].
WebDAV notifications also defines new properties on principal
resources, which are defined in RFC3744 [RFC3744].
5. Notifications
When this feature is available, a DAV:notification-URL
(Section 5.2.1) property appears on principal resources for those
principals who are able to receive notifications. That property
specifies a single DAV:href element whose content refers to a WebDAV
collection resource. Notification "messages" are deposited into this
collection and can be retrieved by clients and acted on accordingly.
The notification collection referenced by the DAV:notification-URL
(Section 5.2.1) property MUST have a DAV:resourcetype property with
DAV:collection and DAV:notifications (Section 5.4.1) child elements.
Notification "messages" are XML documents stored as resources in the
notification collection. Each XML document contains a
DAV:notification (Section 5.4.2) element as its root. The root
element contains a DAV:dtstamp element, and one additional element
which represents the type of notification being conveyed in the
message. That child element will typically contain additional
content that describes the notification.
Each notification resource has a DAV:notificationtype (Section 5.3.1)
property which contains as its single child element an empty element
that matches the child element of the notification resource XML
document root. Any attributes on the child element in the XML
document are also present in the property child element.
Notifications are automatically generated by the server with an
appropriate resource stored in the notifications collection of the
user to whom the notification is targeted. Clients SHOULD monitor
Daboo & Pot Expires February 20, 2015 [Page 3]
Internet-Draft WebDAV User Notifications August 2014
the notification collection looking for new notification resources.
When doing so, clients SHOULD look at the DAV:notificationtype
(Section 5.3.1) property to ensure that the notification is of a type
that the client can handle. Once a client has handled the
notification in whatever way is appropriate it SHOULD delete the
notification resource. Clients SHOULD remove notifications being
displayed to a user when the notification resource is removed from
the notification collection, to enable the user to dismiss a
notification on one device and have it automatically removed from
others. Clients MUST ignore all notifications for types they do not
recognize. Servers MAY delete notification resources on their own if
they determine that the notifications are no longer relevant or
valid. Servers MAY coalesce notifications as appropriate.
Servers MUST prevent clients from adding resources in the
notification collection.
5.1. Mime type
The "application/davnotification+xml" MIME media type MUST be used
for transfer of WebDAV notifications.
This is an example of a Content-Type header:
Content-Type: application/davnotification+xml
HTTP GET requests that expect to receive a WebDAV notification
resource, SHOULD include an "Accept" header that includes
"application/davnotification+xml".
Requests that do not include this header, SHOULD be rejected with a
HTTP 406 status code.
5.2. Additional Principal Properties
This section defines new properties for WebDAV principal resources as
defined in RFC3744 [RFC3744]. These properties are likely to be
protected but the server MAY allow them to be written by appropriate
users.
5.2.1. DAV:notification-URL Property
Name: notification-URL
Namespace: DAV:
Purpose: Identify the URL of the notification collection owned by
the associated principal resource.
Daboo & Pot Expires February 20, 2015 [Page 4]
Internet-Draft WebDAV User Notifications August 2014
Protected: This property SHOULD be protected.
PROPFIND behavior: This property SHOULD NOT be returned by a
PROPFIND allprop request (as defined in Section 14.2 of
[RFC4918]).
COPY/MOVE behavior: This property value SHOULD be preserved in COPY
and MOVE operations.
Description: This property is needed for a client to determine where
the notification collection of the current user is located so that
processing of notification messages can occur. If not present,
then the associated principal is not enabled for notification
messages on the server.
Definition:
<!ELEMENT notification-URL (DAV:href)>
5.3. Properties on Notification Resources
The following new WebDAV properties are defined for notification
resources.
5.3.1. DAV:notificationtype Property
Name: notificationtype
Namespace: DAV:
Purpose: Identify the type of notification of the corresponding
resource.
Protected: This property MUST be protected.
PROPFIND behavior: This property SHOULD NOT be returned by a
PROPFIND allprop request (as defined in Section 14.2 of
[RFC4918]).
COPY/MOVE behavior: This property value MUST be preserved in COPY
and MOVE operations.
Description: This property allows a client, via a PROPFIND Depth:1
request, to quickly find notification messages that the client can
handle in a notification collection. The single child element is
the notification resource root element's child defining the
notification itself. This element MUST be empty, though any
Daboo & Pot Expires February 20, 2015 [Page 5]
Internet-Draft WebDAV User Notifications August 2014
attributes on the element in the notification resource MUST be
present in the property element.
Definition:
<!ELEMENT notificationtype ANY>
<!-- Child elements are empty but will have appropriate attributes.
Any valid notification message child element can appear.-->
5.4. XML Element Definitions
5.4.1. DAV:notifications
Name: notifications
Namespace: DAV:
Purpose: Indicates a notification collection.
Description: This XML element is used in a DAV:resourcetype element
to indicate that the corresponding resource is a notification
collection.
Definition:
<!ELEMENT notifications EMPTY>
5.4.2. DAV:notification
Name: notification
Namespace: DAV:
Purpose: Notification message root element.
Description: The root element used in notification resources.
Definition:
<!ELEMENT notification (dtstamp, XXX) >
<!-- Any notification type element can appear after
DAV:dtstamp -->
5.4.3. DAV:dtstamp
Name: dtstamp
Namespace: DAV:
Daboo & Pot Expires February 20, 2015 [Page 6]
Internet-Draft WebDAV User Notifications August 2014
Purpose: Date-time stamp.
Description: DAV:dtstamp is an element whose content MUST conform to
the "date-time" production in [RFC3339]. In addition, an
uppercase "T" character MUST be used to separate date and time,
and an uppercase "Z" character MUST be present.
Definition:
<!ELEMENT dtstamp (#PCDATA)>
<!-- Value is a date-time in UTZ as per [RFC3339] -->
6. Notification Definitions
This section defines a set of common notification types.
6.1. System Status Notification
The system status notification is used to convey an URI and/or
textual description to the user. The assumption is that the URI
points to a webpage where the current system status is described in
detail, with the provided description being a summary of that. A
"type" attribute on the element is used to indicate the importance of
the current status notification, and has the values "low", "medium"
and "high", representing the increasing level of importance of the
message respectively.
Servers might have knowledge of an agent's language preferences, in
which case it MAY localise the DAV:description value as appropriate
based on the calendar user accessing the notification, but if it
does, it SHOULD include an xml:lang attribute on the DAV:description
element to indicate what language is being used.
6.1.1. DAV:systemstatus Element Definition
Name: systemstatus
Namespace: DAV:
Purpose: Indicates a system status notification.
Description: This XML element is used in a DAV:notification element
to describe a system status notification.
Definition:
Daboo & Pot Expires February 20, 2015 [Page 7]
Internet-Draft WebDAV User Notifications August 2014
<!ELEMENT systemstatus (DAV:href?, DAV:description?)>
<!ATTLIST systemstatus type (low | medium | high) "low">
<!-- One of DAV:href or DAV:description MUST be present -->
Example: This is an example of the body of a notification resource
for an emergency system outage:
<?xml version="1.0" encoding="UTF-8"?>
<D:notification xmlns:D="DAV:">
<D:dtstamp>2011-12-09T11:12:53-05:00</D:dtstamp>
<D:systemstatus type="high">
<D:href>http://example.com/emergency_shutdown.html</D:href>
<D:description xml:lang='en_US'>
Emergency shutdown now
</D:description>
</D:systemstatus>
</D:notification>
Example: This is an example of the WebDAV property on the example
notification resource above:
<?xml version="1.0" encoding="UTF-8"?>
<D:notificationtype xmlns:D="DAV:">
<D:systemstatus type="high" />
</D:notificationtype>
7. Security Considerations
TBD: More?
8. IANA Considerations
This document defines a MIME media type for use of WebDAV
notifications in an XML format. This media type SHOULD be used for
the transfer of WebDAV notifications.
Type name: application
Subtype name: davnotification+xml
Required parameters: none
Optional parameters: none
Encoding considerations: Identical to those of "application/xml" as
described in RFC7303 [RFC7303].
Security considerations: See Section 7.
Daboo & Pot Expires February 20, 2015 [Page 8]
Internet-Draft WebDAV User Notifications August 2014
Interoperability considerations: There are no known interoperability
issues.
Published specification: This specification.
Applications that use this media type: No known applications
currently use this media type.
Fragment identifier considerations: N/A.
Additional information
Deprecated alias names for this type N/A.
Magic number(s) N/A.
File extension(s) xml
Macintosh file type code(s) TEXT
Person & email address to contact for further information:
Intended usage COMMON
Restrictions on usage There are no restrictions on where this media
Author See the "Authors' Addresses" section of this document.
Change Controller IETF
9. Acknowledgments
This specification is the result of discussions between the various
Apple calendar server and client teams.
10. References
10.1. Normative References
[RFC2119] Bradner, S., "Key words for use in RFCs to Indicate
Requirement Levels", BCP 14, RFC 2119, March 1997.
[RFC3339] Klyne, G., Ed. and C. Newman, "Date and Time on the
Internet: Timestamps", RFC 3339, July 2002.
[RFC4918] Dusseault, L., "HTTP Extensions for Web Distributed
Authoring and Versioning (WebDAV)", RFC 4918, June 2007.
Daboo & Pot Expires February 20, 2015 [Page 9]
Internet-Draft WebDAV User Notifications August 2014
[RFC6352] Daboo, C., "CardDAV: vCard Extensions to Web Distributed
Authoring and Versioning (WebDAV)", RFC 6352, August 2011.
[RFC7303] Thompson, H. and C. Lilley, "XML Media Types", RFC 7303,
July 2014.
10.2. Informative References
[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. Backwards-compatibility with earlier drafts
An earlier draft of this specification is already widely deployed
among both servers and clients.
This specification, informally known as 'caldav-notifications'
largely uses the same structure as this specification, but where the
"DAV:" xml namespace is used in this specification, the earlier draft
uses "http://calendarserver.org/ns/".
It is possible to conform to both that draft and this specification
by either creating two different collections, as identified by
"notification-URL" in each respective namespace. Alternatively it's
possible to use the same resource for both, but use content-
negotation using the Accept header to ask the server for a specific
representation of a notification.
Authors' Addresses
Cyrus Daboo
Apple Inc.
1 Infinite Loop
Cupertino, CA 95014
USA
Email: [email protected]
URI: http://www.apple.com/
Daboo & Pot Expires February 20, 2015 [Page 10]
Internet-Draft WebDAV User Notifications August 2014
Evert Pot
fruux GmbH
Koenigsstrasse 32
Muenster, NRW 48143
Germany
Email: [email protected]
URI: https://fruux.com/
Daboo & Pot Expires February 20, 2015 [Page 11]