idnits 2.17.1 draft-ietf-morg-list-specialuse-04.txt: Checking boilerplate required by RFC 5378 and the IETF Trust (see https://trustee.ietf.org/license-info): ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/1id-guidelines.txt: ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/checklist : ---------------------------------------------------------------------------- No issues found here. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year -- The document date (December 1, 2010) is 4894 days in the past. Is this intentional? Checking references for intended status: Proposed Standard ---------------------------------------------------------------------------- (See RFCs 3967 and 4897 for information about using normative references to lower-maturity documents in RFCs) ** Obsolete normative reference: RFC 3501 (Obsoleted by RFC 9051) -- Obsolete informational reference (is this intentional?): RFC 3348 (Obsoleted by RFC 5258) Summary: 1 error (**), 0 flaws (~~), 1 warning (==), 2 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 Message ORGanization Working Group B. Leiba 3 Internet-Draft Huawei Technologies 4 Intended status: Standards Track J. Nicolson 5 Expires: June 4, 2011 Google 6 December 1, 2010 8 IMAP LIST extension for special-use mailboxes 9 draft-ietf-morg-list-specialuse-04 11 Abstract 13 Some IMAP message stores include special-use mailboxes, such as those 14 used to hold draft messages or sent messages. Many mail clients 15 allow users to specify where draft or sent messages should be put, 16 but configuring them requires that the user know which mailboxes the 17 server has set aside for these purposes. This extension adds new 18 mailbox flags that a server MAY include in IMAP LIST command 19 responses to identify special-use mailboxes to the client, easing 20 configuration. 22 Note 24 A revised version of this draft document will be submitted to the RFC 25 editor as a Proposed Standard for the Internet Community. Discussion 26 and suggestions for improvement are requested, and should be sent to 27 morg@ietf.org. 29 Status of this Memo 31 This Internet-Draft is submitted in full conformance with the 32 provisions of BCP 78 and BCP 79. 34 Internet-Drafts are working documents of the Internet Engineering 35 Task Force (IETF). Note that other groups may also distribute 36 working documents as Internet-Drafts. The list of current Internet- 37 Drafts is at http://datatracker.ietf.org/drafts/current/. 39 Internet-Drafts are draft documents valid for a maximum of six months 40 and may be updated, replaced, or obsoleted by other documents at any 41 time. It is inappropriate to use Internet-Drafts as reference 42 material or to cite them other than as "work in progress." 44 This Internet-Draft will expire on June 4, 2011. 46 Copyright Notice 48 Copyright (c) 2010 IETF Trust and the persons identified as the 49 document authors. All rights reserved. 51 This document is subject to BCP 78 and the IETF Trust's Legal 52 Provisions Relating to IETF Documents 53 (http://trustee.ietf.org/license-info) in effect on the date of 54 publication of this document. Please review these documents 55 carefully, as they describe your rights and restrictions with respect 56 to this document. Code Components extracted from this document must 57 include Simplified BSD License text as described in Section 4.e of 58 the Trust Legal Provisions and are provided without warranty as 59 described in the Simplified BSD License. 61 Table of Contents 63 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 3 64 1.1. Conventions used in this document . . . . . . . . . . . . . 3 66 2. New mailbox flags identifying special-use mailboxes . . . . 3 68 3. Extension to IMAP CREATE command to set special-use flags . 5 70 4. IMAP METADATA entry for special-use flags . . . . . . . . . 6 72 5. Examples . . . . . . . . . . . . . . . . . . . . . . . . . . 6 73 5.1. Example of an IMAP LIST command . . . . . . . . . . . . . . 6 74 5.2. Example of an extended IMAP LIST command . . . . . . . . . . 7 75 5.3. Example of an IMAP CREATE command . . . . . . . . . . . . . 7 76 5.4. Example of using IMAP METADATA to manipulate special-use 77 flags . . . . . . . . . . . . . . . . . . . . . . . . . . . 8 79 6. Formal Syntax . . . . . . . . . . . . . . . . . . . . . . . 9 81 7. Security Considerations . . . . . . . . . . . . . . . . . . 9 83 8. IANA Considerations . . . . . . . . . . . . . . . . . . . . 10 84 8.1. Registration of USEFLAG IMAP response code . . . . . . . . . 10 85 8.2. Registration of CREATE-SPECIAL-USE IMAP capability . . . . . 10 86 8.3. Registration of SPECIAL-USE IMAP capability . . . . . . . . 10 87 8.4. Registration of SPECIAL-USE selection option . . . . . . . . 10 88 8.5. Registration of SPECIAL-USE return option . . . . . . . . . 10 89 8.6. Registration of SPECIAL-USE metadata . . . . . . . . . . . . 11 91 9. References . . . . . . . . . . . . . . . . . . . . . . . . . 11 92 9.1. Normative References . . . . . . . . . . . . . . . . . . . . 11 93 9.2. Informative References . . . . . . . . . . . . . . . . . . . 12 95 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . 12 97 1. Introduction 99 Some IMAP message stores include special-use mailboxes, such as those 100 used to hold draft messages or sent messages. Many mail clients 101 allow users to specify where draft or sent messages should be put, 102 but configuring them requires that the user know which mailboxes the 103 server has set aside for these purposes. This extension adds new 104 mailbox flags that a server MAY include in IMAP LIST command 105 responses to identify special-use mailboxes to the client, easing 106 configuration. 108 In addition, this extension adds an OPTIONAL parameter on the IMAP 109 CREATE command, allowing a client to assign a special use to a 110 mailbox when it is created. Servers MAY choose to support this part 111 of the extension, but are not required to. 113 1.1. Conventions used in this document 115 In examples, "C:" indicates lines sent by a client that is connected 116 to a server. "S:" indicates lines sent by the server to the client. 118 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 119 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this 120 document are to be interpreted as described in RFC 2119 [RFC2119]. 122 2. New mailbox flags identifying special-use mailboxes 124 An IMAP server that supports this extension MAY include any or all of 125 the following flags in responses to the non-extended IMAP LIST 126 command. The new flags are included along with existing flags, such 127 as "\Marked" and "\Noselect". A given mailbox may have none, one, or 128 more than one of these flags. In some cases, a special use is advice 129 to a client about what to put in that mailbox. In other cases, it's 130 advice to a client about what to expect to find there. There is no 131 capability string related to the support of special-use flags on the 132 non-extended LIST command. 134 For the extended list command [RFC5258], this extension adds a new 135 capability string, a new selection option, and a new return option, 136 all called "SPECIAL-USE". Supporting implementations MUST include 137 the "SPECIAL-USE" capability string in response to an IMAP CAPABILITY 138 command. If the client specifies the "SPECIAL-USE" selection option, 139 the LIST command MUST return only those mailboxes that have a 140 special-use flag set. If the client specifies the "SPECIAL-USE" 141 return option, the LIST command MUST return the new special-use flags 142 on those mailboxes that have them set. The "SPECIAL-USE" return 143 option is implied by the "SPECIAL-USE" selection option. The 144 extended LIST command MAY return SPECIAL-USE flags even if the client 145 does not specify the return option. 147 The new flags defined here are as follows: 149 \Drafts 150 This mailbox is used to hold draft messages -- typically, 151 messages that are being composed but have not yet been sent. In 152 some server implementations, this might be a virtual mailbox, 153 containing messages from other mailboxes that are marked with 154 the "\Draft" message flag. Alternatively, this might just be 155 advice that a client put drafts here. 157 \Flagged 158 This mailbox presents all messages marked in some way as 159 "important". When this special use is supported, it is likely 160 to represent a virtual mailbox collecting messages (from other 161 mailboxes) that are marked with the "\Flagged" message flag. 163 \Junk 164 This mailbox is where messages deemed to be junk mail are held. 165 Some server implementations might put messages here 166 automatically. Alternatively, this might just be advice to a 167 client-side spam filter. 169 \Sent 170 This mailbox is used to hold copies of messages that have been 171 sent. Some server implementations might put messages here 172 automatically. Alternatively, this might just be advice that a 173 client save sent messages here. 175 \Trash 176 This mailbox is used to hold messages that have been deleted, or 177 marked for deletion. In some server implementations, this might 178 be a virtual mailbox, containing messages from other mailboxes 179 that are marked with the "\Deleted" message flag. 180 Alternatively, this might just be advice that a client that 181 chooses not to use the IMAP "\Deleted" model should use this as 182 its trash location. In server implementations that strictly 183 expect the IMAP "\Deleted" model, this special use is likely not 184 to be supported. 186 \All 187 This mailbox presents all messages in the user's message store. 188 Implementations MAY omit some messages, such as, perhaps, those 189 in \Trash and \Junk. When this special use is supported, it is 190 almost certain to represent a virtual mailbox. 192 \Archive 193 This mailbox is used to archive messages. The meaning of an 194 "archival" mailbox is server-dependent; typically, it will be 195 used to get messages out of the inbox, or otherwise keep them 196 out of the user's way, while still making them accessible. 198 All of the above flags are OPTIONAL, and any given server or message 199 store may support any combination of the flags, or none at all. In 200 some server or message store implementations it might be possible for 201 multiple mailboxes to have the same special-use flag. 203 Special-use flags are likely to be user-specific. User Adam might 204 share his \Sent mailbox with user Barb, but that mailbox is unlikely 205 to also serve as Barb's \Sent mailbox. It's certainly possible for 206 Adam and Barb to each set the \Sent use on the same mailbox, but that 207 would be done by specific action (see the sections below). 209 3. Extension to IMAP CREATE command to set special-use flags 211 As an OPTIONAL feature, a server MAY allow clients to designate a 212 mailbox, at creation, as having one or more special uses. This 213 extension defines the "USE" parameter to the IMAP CREATE command for 214 that purpose (using the syntax defined in RFC 4466 section 2.2 215 [RFC4466]). The new OPTIONAL "USE" parameter is followed by a 216 parenthesized list of zero or more special-use flags, as defined 217 above. 219 In some server implementations, some special uses may imply automatic 220 action by the server. For example, creation of a "\Junk" mailbox 221 might cause the server to start placing messages that have been 222 evaluated as spam into the mailbox. 224 In some server implementations, some special uses may result in a 225 mailbox with unusual characteristics or side effects. For example, 226 creation of an "\All" mailbox might cause the server to create a 227 virtual mailbox, rather than a standard one, and that mailbox might 228 behave in unexpected ways (COPY into it might fail, for example). 230 Servers MAY allow the creation of a special-use mailbox even if one 231 so designated already exists, having the effect of moving the special 232 use from the old mailbox to the new one. Alternatively, servers MAY 233 refuse the creation, considering the designation to be a conflict. 235 If the server can not create a mailbox with the designated special 236 use defined, for whatever reason, it MUST NOT create the mailbox, and 237 MUST respond to the CREATE command with a tagged NO response. If the 238 reason for the failure is related to the special-use flag (the 239 specified special use is not supported or cannot be assigned to the 240 specified mailbox), the server SHOULD include the new "USEFLAG" 241 response code in the tagged response (see Section 5.3 for an 242 example). 244 An IMAP server that supports this OPTIONAL feature will advertise the 245 CREATE-SPECIAL-USE capability string. Clients MUST NOT use the "USE" 246 parameter unless the server advertises the capability. Note that 247 this capability string is different from the SPECIAL-USE string 248 defined above, and a server that supports both functions MUST 249 advertise both capability strings. 251 4. IMAP METADATA entry for special-use flags 253 If a server supports this extension and the METADATA extension 254 [RFC5464], it SHOULD tie the special-use flags for a mailbox to its 255 metadata entry "/shared/specialuse". The value of /shared/specialuse 256 is either NIL (if there are no special-use flags for that mailbox) or 257 a space-separated list of special-use flags, presented the same way 258 they would be presented in the LIST command response. 260 Such a server MAY allow the setting of special-use flags through the 261 METADATA mechanisms, thereby allowing clients to change the special 262 uses of existing mailboxes. These changes might have side effects, 263 as the server automatically adjusts the special uses accordingly, 264 just as it might do with CREATE USE, above. See Section 5.4 for an 265 example. 267 A server that supports this MUST check the validity of changes to the 268 special-use flags that are done through the metadata. It MUST NOT 269 allow a client to set invalid or unsupported flags, nor to create 270 conflicting or otherwise invalid situations. 272 5. Examples 274 5.1. Example of an IMAP LIST command 276 This example shows an IMAP LIST response from a server that supports 277 this extension. Note that not all of the flags are used. This 278 server also supports the Child Mailbox extension [RFC3348]. 280 C: t1 LIST "" "%" 281 S: * LIST (\Marked \HasNoChildren) "/" Inbox 282 S: * LIST (\HasNoChildren) "/" ToDo 283 S: * LIST (\HasChildren) "/" Projects 284 S: * LIST (\Sent \HasNoChildren) "/" SentMail 285 S: * LIST (\Marked \Drafts \HasNoChildren) "/" MyDrafts 286 S: * LIST (\Trash \HasNoChildren) "/" Trash 287 S: t1 OK done 289 5.2. Example of an extended IMAP LIST command 291 This example shows an IMAP LIST response from a server that supports 292 this extension. The client uses the extended IMAP LIST command. 294 C: t1 CAPABILITY 295 S: * CAPABILITY IMAP4rev1 SPECIAL-USE 296 S: t1 OK done 298 C: t2 LIST "" "%" RETURN (SPECIAL-USE) 299 S: * LIST (\Marked) "/" Inbox 300 S: * LIST () "/" ToDo 301 S: * LIST () "/" Projects 302 S: * LIST (\Sent) "/" SentMail 303 S: * LIST (\Marked \Drafts) "/" MyDrafts 304 S: * LIST (\Trash) "/" Trash 305 S: t2 OK done 307 Here, the client also includes the "SPECIAL-USE" selection option for 308 the same list. The "SPECIAL-USE" return option could also have been 309 specified, but it is unnecessary, as it is implied by the selection 310 option. Note that in this case, mailboxes that do not have a 311 special-use flag are not listed. Also note that we've used the 312 wildcard "*", rather than "%", to make sure we see all special-use 313 mailboxes, even ones that might not be at the namespace's root. 315 C: t3 LIST (SPECIAL-USE) "" "*" 316 S: * LIST (\Sent) "/" SentMail 317 S: * LIST (\Marked \Drafts) "/" MyDrafts 318 S: * LIST (\Trash) "/" Trash 319 S: t3 OK done 321 5.3. Example of an IMAP CREATE command 323 This example shows an IMAP CREATE command that might be used to 324 create a mailbox designated to hold draft and sent messages. It also 325 attempts to create a mailbox that will contain all the user's 326 messages, but the server does not support that special use for this 327 user's message store. 329 C: t1 CAPABILITY 330 S: * CAPABILITY IMAP4rev1 CREATE-SPECIAL-USE 331 S: t1 OK done 333 C: t2 CREATE MySpecial (USE (\Drafts \Sent)) 334 S: t2 OK MySpecial created 336 C: t3 CREATE Everything (USE (\All)) 337 S: t3 NO [USEFLAG] \All not supported 339 5.4. Example of using IMAP METADATA to manipulate special-use flags 341 This example shows how IMAP METADATA can be used to manipulate 342 special-use flags, if the operation is supported on the server. 344 ==> Starting point: 345 C: t1 LIST "" "%" RETURN (SPECIAL-USE) 346 S: * LIST (\Sent) "/" SentMail 347 S: * LIST (\Drafts) "/" MyDrafts 348 S: * LIST () "/" SavedDrafts 349 S: * LIST (\Trash) "/" Trash 350 S: t1 OK done 352 ==> Demonstrate the connection: 353 C: t2 GETMETADATA "MyDrafts" /shared/specialuse 354 S: * METADATA "MyDrafts" (/shared/specialuse "\Drafts") 355 S: t2 OK done 357 ==> Set new use for SavedDrafts; MyDrafts changes automatically: 358 C: t3 SETMETADATA "SavedDrafts" (/shared/specialuse "\Drafts") 359 S: * METADATA "MyDrafts" (/shared/specialuse NIL) 360 S: t3 OK SETMETADATA complete 362 ==> Remove special use for SentMail: 363 C: t4 SETMETADATA "SentMail" (/shared/specialuse NIL) 364 S: t4 OK SETMETADATA complete 366 ==> Check the results: 367 C: t5 LIST "" "%" RETURN (SPECIAL-USE) 368 S: * LIST () "/" SentMail 369 S: * LIST () "/" MyDrafts 370 S: * LIST (\Drafts) "/" SavedDrafts 371 S: * LIST (\Trash) "/" Trash 372 S: t5 OK done 374 6. Formal Syntax 376 The following syntax specification uses the augmented Backus-Naur 377 Form (BNF) as described in [RFC5234]. 379 create-param =/ "USE" SP "(" [use-flag *(SP use-flag)] ")" 380 ; Extends "create-param" from RFC 4466 [RFC4466] 382 mbx-list-oflag =/ use-flag 383 ; Extends "mbx-list-oflag" from IMAP base [RFC3501] 385 list-select-independent-opt =/ "SPECIAL-USE" 386 ; Extends "list-select-independent-opt" from 387 ; LIST-extended [RFC5258] 389 return-option =/ "SPECIAL-USE" 390 ; Extends "return-option" from 391 ; LIST-extended [RFC5258] 393 resp-text-code =/ "USEFLAG" 394 ; Extends "resp-text-code" from 395 ; IMAP [RFC3501] 397 use-flag = "\All" / "\Archive" / "\Drafts" / "\Flagged" / 398 "\Junk" / "\Sent" / "\Trash" / use-flag-ext 400 use-flag-ext = "\" atom 401 ; Reserved for future extensions. Clients 402 ; MUST ignore list flags they do not understand 403 ; Server implementations MUST NOT generate 404 ; extension flags except as defined by 405 ; future standards-track revisions of or 406 ; extensions to this specification. 408 7. Security Considerations 410 LIST response: There are no security issues with conveying special- 411 use information to a client. 413 CREATE command "USE" parameter: In some server implementations, some 414 special uses may imply automatic action by the server. For example, 415 creation of a "\Junk" mailbox might cause the server to start placing 416 messages that have been evaluated as spam into the mailbox. 417 Implementors SHOULD consider the consequences of allowing a user (or 418 client program) to designate the target of such automatic action. 420 8. IANA Considerations 422 8.1. Registration of USEFLAG IMAP response code 424 This document defines a new IMAP response code. IANA is asked to add 425 "USEFLAG" to the IMAP Response Codes registry. 427 8.2. Registration of CREATE-SPECIAL-USE IMAP capability 429 This document defines a new IMAP capability. IANA is asked to add 430 "CREATE-SPECIAL-USE" to the IMAP 4 Capabilities registry. 432 8.3. Registration of SPECIAL-USE IMAP capability 434 This document defines a new IMAP capability. IANA is asked to add 435 "SPECIAL-USE" to the IMAP 4 Capabilities registry. 437 8.4. Registration of SPECIAL-USE selection option 439 This document defines a new IMAP4 List Extended selection option. 440 IANA is asked to add "SPECIAL-USE" to the IMAP4 List Extended 441 registry, as follows: 443 To: iana@iana.org 444 Subject: Registration of LIST-EXTENDED selection option SPECIAL-USE 445 LIST-EXTENDED option name: SPECIAL-USE 446 LIST-EXTENDED option type: SELECTION 447 Implied return option(s): SPECIAL-USE 448 LIST-EXTENDED option description: Limit the list to special-use 449 mailboxes only 450 Published specification: [[this RFC]] 451 Security considerations: none 452 Intended usage: COMMON 453 Person and email address to contact for further information: Authors' 454 Addresses at the end of [[this RFC]] 455 Owner/Change controller: iesg@ietf.org 457 8.5. Registration of SPECIAL-USE return option 459 This document defines a new IMAP4 List Extended return option. IANA 460 is asked to add "SPECIAL-USE" to the IMAP4 List Extended registry, as 461 follows: 463 To: iana@iana.org 464 Subject: Registration of LIST-EXTENDED return option SPECIAL-USE 465 LIST-EXTENDED option name: SPECIAL-USE 466 LIST-EXTENDED option type: RETURN 467 LIST-EXTENDED option description: Request special-use mailbox 468 information 469 Published specification: [[this RFC]] 470 Security considerations: none 471 Intended usage: COMMON 472 Person and email address to contact for further information: Authors' 473 Addresses at the end of [[this RFC]] 474 Owner/Change controller: iesg@ietf.org 476 8.6. Registration of SPECIAL-USE metadata 478 This document defines a new IMAP METADATA entry. IANA is asked to 479 add the following to the IMAP METADATA Mailbox Entry registry: 481 To: iana@iana.org 482 Subject: IMAP METADATA Entry Registration 483 Type: Mailbox 484 Name: /shared/specialuse 485 Description: Defines any special-use features of a mailbox. See the 486 reference specification for details of its use. 487 Content-type: text/plain; charset=us-ascii 488 RFC Number: [[this RFC]] 489 Contact: MORG mailing list mailto:morg@ietf.org 491 9. References 493 9.1. Normative References 495 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 496 Requirement Levels", BCP 14, RFC 2119, March 1997. 498 [RFC3501] Crispin, M., "INTERNET MESSAGE ACCESS PROTOCOL - VERSION 499 4rev1", RFC 3501, March 2003. 501 [RFC4466] Melnikov, A. and C. Daboo, "Collected Extensions to IMAP4 502 ABNF", RFC 4466, April 2006. 504 [RFC5234] Crocker, D. and P. Overell, "Augmented BNF for Syntax 505 Specifications: ABNF", STD 68, RFC 5234, January 2008. 507 [RFC5258] Leiba, B. and A. Melnikov, "Internet Message Access 508 Protocol version 4 - LIST Command Extensions", RFC 5258, 509 June 2008. 511 [RFC5464] Daboo, C., "The IMAP METADATA Extension", RFC 5464, 512 February 2009. 514 9.2. Informative References 516 [RFC3348] Gahrns, M. and R. Cheng, "The Internet Message Action 517 Protocol (IMAP4) Child Mailbox Extension", RFC 3348, 518 July 2002. 520 Authors' Addresses 522 Barry Leiba 523 Huawei Technologies 525 Phone: +1 646 827 0648 526 Email: barryleiba@computer.org 527 URI: http://internetmessagingtechnology.org/ 529 Jamie Nicolson 530 Google 532 Email: nicolson@google.com