rfc-7889

The IMAP APPENDLIMIT Extension

J. SrimushnamBoovaraghamoorthy, N. Bisht
date2016-05 streamIETF areaart wgimapapnd statusPROPOSED STANDARD pages7 canonicalhttps://www.rfc-editor.org/rfc/rfc7889 doi10.17487/RFC7889 errataview
This document defines an extension to the IMAP service whereby a server can inform the client about maximum message upload sizes, allowing the client to avoid sending APPEND commands that will fail because the messages are too large.

Extracted elements (15)

design-rationale §3.3

Computing the APPENDLIMIT should be fast and must not take ACLs, quotas, or other dynamic policy into account. The APPENDLIMIT is a static policy hint; APPEND may still fail for ACL or quota reasons even when the message is within the limit.

email

design-rationale §1

The extension was motivated by mobile device resource consumption: non-synchronizing literals caused IMAP clients to transmit large attachments before receiving a rejection, wasting battery and mobile data when the server's upload limit was not known in advance.

email

interoperability-note §2

An IMAP client implementing this extension should be able to parse both mailbox-specific (per-mailbox STATUS/LIST responses) and global (CAPABILITY response) APPENDLIMIT forms, as servers may use either.

email

interoperability-note §3.2

If the server does not support the STATUS return option on the LIST command, the client should fall back to issuing individual STATUS commands per mailbox to obtain APPENDLIMIT values.

email

normative-requirement §4 SHOULD

A client SHOULD avoid use of non-synchronizing literals (RFC 7888) when the maximum upload size supported by the IMAP server is unknown, to prevent wasting bandwidth and device resources on a doomed APPEND.

email

normative-requirement §4 REQUIRED

If a client uploads a message that exceeds the maximum upload size for a mailbox, the server SHALL reject the APPEND command with a tagged TOOBIG response code as defined in RFC 4469.

email

normative-requirement §3.2 MUST

The IMAP server MUST recognize the APPENDLIMIT attribute in a LIST command with a STATUS return option and include an appropriate STATUS response for each matching mailbox.

email

protocol-element §3.1

A new APPENDLIMIT attribute is added to the STATUS command, allowing clients to retrieve the maximum upload size for a specific mailbox. The server returns 'APPENDLIMIT <number>' or 'APPENDLIMIT NIL' (no limit) in the STATUS response.

email

protocol-element §2

APPENDLIMIT=<number> in the capability list indicates a single upload limit in octets applied uniformly to all mailboxes. A value of 0 means the server will not accept any APPEND commands at all for affected mailboxes.

email

protocol-element §2

APPENDLIMIT without a value in the capability list signals that per-mailbox limits apply; the client must query each mailbox individually via STATUS or LIST to determine its specific limit.

email

protocol-element §2

The APPENDLIMIT extension is advertised in the CAPABILITY response as either 'APPENDLIMIT=<number>' (global limit for all mailboxes) or 'APPENDLIMIT' without a value (per-mailbox limits discoverable via STATUS or LIST).

email, registry

protocol-element §3.2

When the server supports LIST-STATUS (RFC 5819), the client may issue a LIST command with 'RETURN (STATUS (APPENDLIMIT))' to retrieve per-mailbox APPENDLIMIT values in a single round trip.

email

registry §7

IANA has added 'APPENDLIMIT' to the 'IMAP Capabilities' registry, referencing RFC 7889 as the defining document.

email, registry

security-consideration §6

The APPENDLIMIT extension provides only an optimization hint for cooperative clients and does not introduce new security concerns. It does not protect against abusive clients intentionally consuming server resources; servers must still disconnect or restrict such clients independently.

email, security

wire-format §5

The ABNF extends 'capability' to include 'APPENDLIMIT' optionally followed by '=' and a number. 'status-att' gains 'APPENDLIMIT', and 'status-att-val' gains 'APPENDLIMIT SP (number / nil)' where number is the maximum size in octets.

email