-
Notifications
You must be signed in to change notification settings - Fork 0
/
draft-murchison-imap-list-metadata.xml
317 lines (292 loc) · 11.4 KB
/
draft-murchison-imap-list-metadata.xml
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
<?xml version='1.0' encoding='utf-8'?>
<!DOCTYPE rfc [
<!ENTITY nbsp " ">
<!ENTITY zwsp "​">
<!ENTITY nbhy "‑">
<!ENTITY wj "⁠">
]>
<?xml-stylesheet type='text/xsl' href='rfc2629.xslt' ?>
<?rfc toc="yes"?>
<?rfc symrefs="yes"?>
<?rfc sortrefs="yes"?>
<?rfc compact="yes"?>
<?rfc strict="yes"?>
<rfc xmlns:xi="http://www.w3.org/2001/XInclude"
category="std"
ipr="trust200902"
docName="draft-murchison-imap-list-metadata-02"
obsoletes=""
updates=""
submissionType="IETF"
xml:lang="en"
tocInclude="true"
symRefs="true"
sortRefs="true"
consensus="true"
version="3">
<!-- xml2rfc v2v3 conversion 3.14.2 -->
<front>
<title abbrev="IMAP LIST-METADATA">IMAP4 Extension for Returning
Mailbox METADATA in Extended LIST</title>
<seriesInfo name="Internet-Draft"
value="draft-murchison-imap-list-metadata-02"/>
<author initials="K." surname="Murchison" fullname="Kenneth Murchison">
<organization abbrev="Fastmail">Fastmail US LLC</organization>
<address>
<postal>
<street>1429 Walnut Street - Suite 1201</street>
<city>Philadelphia</city> <region>PA</region>
<code>19102</code> <country>USA</country>
</postal>
<email>[email protected]</email>
</address>
</author>
<author initials="B." surname="Gondwana" fullname="Bron Gondwana">
<organization abbrev="Fastmail">Fastmail Pty Ltd</organization>
<address>
<postal>
<street>Level 2, 114 William Street</street>
<city>Melbourne</city>
<region>VIC</region>
<code>3000</code>
<country>Australia</country>
</postal>
<email>[email protected]</email>
</address>
</author>
<date/>
<area>ART</area>
<workgroup>EXTRA</workgroup>
<keyword>IMAP4</keyword>
<keyword>LIST</keyword>
<keyword>METADATA</keyword>
<abstract>
<t>This document defines an extension to the to IMAP LIST
command that allows the client to request mailbox annotations
(metadata), along with other information typically returned by
the LIST command.</t>
</abstract>
</front>
<middle>
<section numbered="true" toc="default">
<name>Introduction</name>
<t>IMAP clients sometimes fetch mailbox metadata (e.g. color) to
augment the display of mailboxes to the logged-in user.
In order to do that, the client is
forced to issue a LIST or LSUB command to list all available
mailboxes, followed by a GETMETADATA command for each mailbox
found. This document defines an extension to the to IMAP LIST
command that is identified by the capability string
"LIST-METADATA". The LIST-METADATA extension allows the client
to request annotations on available mailboxes, along with other
information typically returned by the LIST command.</t>
</section>
<section numbered="true" toc="default">
<name>Conventions Used in This Document</name>
<t>In examples, "C:" indicates lines sent by a client that is connected
to a server. "S:" indicates lines sent by the server to the
client.</t>
<t>The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL
NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED",
"MAY", and "OPTIONAL" in this document are to be interpreted as
described in BCP 14 <xref target="RFC2119"/>
<xref target="RFC8174"/>
when, and only when, they appear in all capitals, as shown here.
</t>
</section>
<!-- Intro -->
<section anchor="metadata" numbered="true" toc="default">
<name>METADATA Return Option to LIST Command</name>
<t><xref target="RFC5464"/> defines the
GETMETADATA command which is
used by an IMAP client to retrieve mailbox annotations.
Sometimes,
a client will have to look up the metadata for some or all of
the mailboxes returned by the LIST command. Doing so in
multiple GETMETADATA commands wastes bandwidth and can degrade
performance if the client does not pipeline the requests.</t>
<t>This document extends the LIST command with a new return option,
"METADATA", which allows the client to request all of the
desired information in a single command. For each listable
mailbox matching the list pattern and selection options, the
server MUST return an untagged LIST response followed by one or more
untagged METADATA responses containing the mailbox annotations
requested by the client.
The untagged METADATA responses to an extended LIST command have
the same syntax and semantics as those that would be returned by
GETMETADATA commands on the same set of listable mailboxes.
As per <xref target="RFC5464"/>, the server may
return all requested annotations in a single METADATA response
for each mailbox, or it may split the requested annotations into
multiple METADATA responses for each mailbox, if it desires.</t>
<t>If the server is unable to look up the annotations for
given mailbox, it MAY drop the corresponding METADATA response.
In such a situation, the LIST command would still return a tagged
OK reply.</t>
</section>
<!-- MYRIGHTS -->
<section numbered="true" toc="default">
<name>Examples</name>
<t>Note that the line wrapping of the extended LIST commands
below is for editorial purposes only.</t>
<t keepWithNext="true">
In this example:
</t>
<ul spacing="normal">
<li>The "color" annotation for the "foo" mailbox has not been
set, so the METADATA response has a value of "NIL" (has no
value).</li>
<li>The "bar" mailbox doesn't exist, so it has no METADATA
response.</li>
</ul>
<artwork name="" type="" align="left" alt=""><![CDATA[
C: A01 LIST "" %
RETURN (METADATA ("/shared/vendor/cmu/cyrus-imapd/color"))
S: * LIST () "." "INBOX"
S: * METADATA INBOX ("/shared/vendor/cmu/cyrus-imapd/color" "#b71c1c")
S: * LIST () "." "foo"
S: * METADATA "foo" ("/shared/vendor/cmu/cyrus-imapd/color" NIL)
S: * LIST (\NonExistent) "." "bar"
S: A01 OK List completed.
]]></artwork>
<t keepWithNext="true">
In this example the LIST response for the "foo" mailbox is
returned because it has matching children, but no METADATA
response is returned because "foo" itself doesn't match the
selection criteria.
</t>
<artwork name="" type="" align="left" alt=""><![CDATA[
C: A02 LIST (SUBSCRIBED RECURSIVEMATCH) "" %
RETURN (METADATA ("/shared/vendor/cmu/cyrus-imapd/color"))
S: * LIST (\Subscribed) "." "INBOX"
S: * METADATA INBOX ("/shared/vendor/cmu/cyrus-imapd/color" "#b71c1c")
S: * LIST () "." "foo" (CHILDINFO ("SUBSCRIBED"))
S: A02 OK List completed.
]]></artwork>
</section>
<section numbered="true" toc="default">
<name>Formal Syntax</name>
<t>The following syntax specification uses the augmented Backus-Naur
Form (BNF) as described in <xref target="RFC5234"/>.
Note that "return-option" is defined in
<xref target="RFC5258"/>
and "entry" is defined in
<xref target="RFC5464"/>.</t>
<artwork name="" type="" align="left" alt=""><![CDATA[
return-option =/ "METADATA" "(" entry *(SP entry) ")"
]]></artwork>
</section>
<section anchor="security" numbered="true" toc="default">
<name>Security Considerations</name>
<t>This specification does not introduce any additional security
concerns beyond those described in
<xref target="RFC5258"/>.</t>
</section>
<section anchor="privacy" numbered="true" toc="default">
<name>Privacy Considerations</name>
<t>This specification does not introduce any additional privacy
concerns beyond those described in
<xref target="RFC5464"/>.</t>
</section>
<section numbered="true" toc="default">
<name>IANA Considerations</name>
<section numbered="true" toc="default">
<name>Registration of IMAP capability LIST-METADATA</name>
<t>This document defines the "LIST-METADATA" IMAP capability
to be added to the registry defined in
<xref target="RFC9051" section="12.1"/>.</t>
</section>
<section numbered="true" toc="default">
<name>Registration of LIST-EXTENDED option METADATA</name>
<t>This section registers the "METADATA" option to be added to the
registry defined in
<xref target="RFC5258" section="9"/>.
</t>
<dl newline="true" spacing="normal">
<dt>LIST-EXTENDED option name:</dt>
<dd>
METADATA
</dd>
<dt>LIST-EXTENDED option type:</dt>
<dd>
RETURN
</dd>
<dt>LIST-EXTENDED option description:</dt>
<dd>
Causes the LIST command to return METADATA responses in
addition to LIST responses.
</dd>
<dt>Published specification:</dt>
<dd>
RFC XXXX, <xref target="metadata"/>
</dd>
<dt>Security considerations:</dt>
<dd>
RFC XXXX, <xref target="security"/>
</dd>
<dt>Intended usage:</dt>
<dd>
COMMON
</dd>
<dt>Person and email address to contact for further information:</dt>
<dd>
Kenneth Murchison <[email protected]>,
Bron Gondwana <[email protected]>
</dd>
<dt>Owner/Change controller:</dt>
<dd>
IESG <[email protected]>
</dd>
</dl>
</section>
</section>
<!-- IANA -->
<!--
<section numbered="true" toc="default">
<name>Acknowledgments</name>
<t>This document is based largely on
<xref target="RFC5819"/>.
The author would like to thank the authors of that document for
providing both inspiration and some borrowed text for this
document.</t>
<t>The author would also like to thank the following individuals for
contributing their ideas and support for writing this
specification: Cyrus Daboo.</t>
</section>
-->
</middle>
<back>
<references>
<name>References</name>
<references>
<name>Normative References</name>
<xi:include href="http://xml2rfc.ietf.org/public/rfc/bibxml/reference.RFC.2119.xml"/>
<xi:include href="http://xml2rfc.ietf.org/public/rfc/bibxml/reference.RFC.5258.xml"/>
<xi:include href="http://xml2rfc.ietf.org/public/rfc/bibxml/reference.RFC.5234.xml"/>
<xi:include href="http://xml2rfc.ietf.org/public/rfc/bibxml/reference.RFC.5464.xml"/>
<xi:include href="http://xml2rfc.ietf.org/public/rfc/bibxml/reference.RFC.8174.xml"/>
<xi:include href="http://xml2rfc.ietf.org/public/rfc/bibxml/reference.RFC.9051.xml"/>
</references>
<!--
<references>
<name>Informative References</name>
<xi:include href="http://xml2rfc.ietf.org/public/rfc/bibxml/reference.RFC.5819.xml"?>
</references>
-->
</references>
<section numbered="true" toc="default">
<name>Change History (To be removed by RFC Editor before publication)</name>
<t>Changes from draft-murchison-imap-list-metadata-01:
</t>
<ul spacing="normal">
<li>None.</li>
</ul>
<t>Changes from draft-murchison-imap-list-metadata-00:
</t>
<ul spacing="normal">
<li>Updated Keywords boilerplate.</li>
<li>Changed RFC 3501 reference to RFC 9051.</li>
</ul>
</section>
</back>
</rfc>