rfc-9007

Handling Message Disposition Notification with the JSON Meta Application Protocol (JMAP)

R. Ouazana (Editor)
date2021-03 streamIETF areaart wgjmap statusPROPOSED STANDARD pages13 canonicalhttps://www.rfc-editor.org/rfc/rfc9007 doi10.17487/RFC9007
This document specifies a data model for handling Message Disposition Notifications (MDNs) (see RFC 8098) in the JSON Meta Application Protocol (JMAP) (see RFCs 8620 and 8621).

Extracted elements (23)

design-rationale §2.2

MDN/parse's 'forEmailId' property can be null or missing when the originalMessageId does not refer to an existing message or when the server cannot efficiently calculate the related message (e.g., multiple messages share the same Message-ID), avoiding a mandatory expensive lookup.

email

design-rationale §2

The 'reportingUA' field (Mail User Agent name) accepts a null value, noted to have better privacy properties, allowing implementations to avoid disclosing client software identity in MDN reports.

email, privacy

design-rationale §2.1

The server is made responsible for generating originalRecipient and originalMessageId (per RFC 8098) rather than the client, since these values must be derived from the authoritative server-side message data rather than potentially stale or spoofed client input.

email

interoperability-note §2.1

If the accountId or identityId given to MDN/send cannot be found, the method call is rejected with an 'invalidArguments' error. Similarly, MDN/parse rejects with 'invalidArguments' if the accountId is not found.

email

interoperability-note §1

Requesting an MDN when sending a message is done via the standard Email/set create method from RFC 8621 by adding a 'Disposition-Notification-To' header field; no separate MDN-specific method is needed for this use case.

email

normative-requirement §1.2 MUST

Because keywords are case insensitive in IMAP but case sensitive in JMAP, the '$mdnsent' keyword MUST always be used in lowercase.

email

normative-requirement §2 MUST

Disposition fields (actionMode, sendingMode, type) are defined as case insensitive in RFC 8098 but are case sensitive in this RFC and MUST be converted to lowercase by MDN/parse when parsing received MDNs.

email, json

normative-requirement §1.1 MUST

Servers MUST support all properties specified for the new data types (MDN and Disposition) defined in this document.

email

normative-requirement §1.3 MUST

Servers that include the 'urn:ietf:params:jmap:mdn' capability in one or more 'accountCapabilities' properties MUST also include the property in the top-level 'capabilities' property of the Session resource.

email

normative-requirement §2 MUST

The actionMode field MUST be one of 'manual-action' or 'automatic-action'; sendingMode MUST be one of 'mdn-sent-manually' or 'mdn-sent-automatically'; type MUST be one of 'deleted', 'dispatched', 'displayed', or 'processed'.

email

normative-requirement §2.1 MUST NOT

The client MUST NOT issue an 'MDN/send' request if the message already has the '$mdnsent' keyword set. If the keyword is already set, the server returns an 'mdnAlreadySent' error.

email

normative-requirement §2 MUST NOT

The 'forEmailId' property MUST NOT be null for MDN/send requests, though it MAY be null in responses from MDN/parse when the original message cannot be identified.

email

normative-requirement §2.1 MUST

The server MUST reject an MDN/send that does not result in setting the '$mdnsent' keyword; it MUST check that 'onSuccessUpdateEmail' is correctly set to update this keyword. This ensures the client explicitly tracks which messages have had MDNs sent.

email

normative-requirement §2.1 MUST

When calling MDN/send, the 'using' property of the Request object MUST contain both 'urn:ietf:params:jmap:mdn' and 'urn:ietf:params:jmap:mail' capabilities, because MDN/send implicitly calls Email/set and uses Identity objects.

email

protocol-element §2.2

MDN/parse takes accountId and blobIds (Id[]) and returns parsed (Id[MDN]|null), notParsable (Id[]|null), and notFound (Id[]|null). It allows a client to extract structured MDN data from arbitrary blobs, such as those referenced in EmailSubmission.mdnBlobIds.

email, json

protocol-element §2.1

MDN/send response includes sent (Id[MDN]|null) containing server-set properties omitted by the client, and notSent (Id[SetError]|null). Recognized SetError types include notFound, forbidden, forbiddenFrom, overQuota, tooLarge, rateLimit, invalidProperties, and the new mdnAlreadySent.

email, json

protocol-element §2.1

MDN/send takes arguments: accountId (Id), identityId (Id), send (Id[MDN] map of creation id to MDN objects), and onSuccessUpdateEmail (Id[PatchObject]|null). The server uses the identity to determine the sender and derive the finalRecipient; it generates originalRecipient and originalMessageId per RFC 8098.

email, json

protocol-element §2

The Disposition object embedded in MDN has three required string properties: actionMode ('manual-action' or 'automatic-action'), sendingMode ('mdn-sent-manually' or 'mdn-sent-automatically'), and type ('deleted', 'dispatched', 'displayed', or 'processed'). These correspond to RFC 8098 disposition fields.

email, json

protocol-element §2

The MDN object models a Message Disposition Notification and includes properties: forEmailId, subject, textBody, includeOriginalMessage, reportingUA, disposition, mdnGateway, originalRecipient, finalRecipient, originalMessageId, error, and extensionFields. Server-set fields (mdnGateway, originalRecipient, originalMessageId, error) are populated by the server during MDN/send.

email, json

registry §4.2

IANA has registered the 'mdnAlreadySent' error code in the JMAP Error Codes registry. It indicates the message already has the '$mdnsent' keyword and the client MUST NOT retry sending an MDN for that message.

email, registry

registry §4.1

IANA has registered 'urn:ietf:params:jmap:mdn' in the JMAP Capabilities registry with intended use 'common', change controller IETF. This capability signals support for the MDN data type and MDN/send and MDN/parse methods.

email, registry

security-consideration §2

Setting 'includeOriginalMessage' to true causes the original message content to appear in the multipart/report MDN; RFC 8098 security considerations regarding content disclosure apply. The field defaults to false.

email, security, privacy

security-consideration §5 SHOULD

To reinforce trust regarding the relation between the user sending a message and their identity, the server SHOULD validate that the user is permitted to use the provided 'finalRecipient' value in conformance with the Identity, and return a 'forbiddenFrom' error if not.

email, security