Re: [Jmap] Attachments and composing more complex MIME structures

Neil Jenkins <neilj@fastmailteam.com> Wed, 09 August 2017 08:12 UTC

Return-Path: <neilj@fastmailteam.com>
X-Original-To: jmap@ietfa.amsl.com
Delivered-To: jmap@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 9F797131E08 for <jmap@ietfa.amsl.com>; Wed, 9 Aug 2017 01:12:53 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.72
X-Spam-Level:
X-Spam-Status: No, score=-2.72 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, SPF_PASS=-0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=fastmailteam.com header.b=WxahQYYX; dkim=pass (2048-bit key) header.d=messagingengine.com header.b=PpNv//4U
Received: from mail.ietf.org ([4.31.198.44]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id HMCL9VkmheBG for <jmap@ietfa.amsl.com>; Wed, 9 Aug 2017 01:12:52 -0700 (PDT)
Received: from out1-smtp.messagingengine.com (out1-smtp.messagingengine.com [66.111.4.25]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id E3FB4127869 for <jmap@ietf.org>; Wed, 9 Aug 2017 01:12:51 -0700 (PDT)
Received: from betaweb1.internal (betaweb1.nyi.internal [10.202.2.10]) by mailout.nyi.internal (Postfix) with ESMTP id DAEEB20B1F for <jmap@ietf.org>; Wed, 9 Aug 2017 04:12:50 -0400 (EDT)
Received: from betaweb1 ([::ffff:10.202.2.10]) by betaweb1.internal (MEProxy); Wed, 09 Aug 2017 04:12:50 -0400
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= fastmailteam.com; h=content-transfer-encoding:content-type:date :from:in-reply-to:message-id:mime-version:references:subject:to :x-me-sender:x-me-sender:x-sasl-enc; s=fm1; bh=BXoCO4vVlasemnenv SOGKq/XgRcEWsY6c29BHm2Mml4=; b=WxahQYYXzxOVF1J5B2VXipaWfN8C2AVrU AkmqgygxfZGUpm5NzZ3B5ejlugIwZzeMXOddGnwD8X7bLjl8cWVVjuz6jGUrThI0 lutKs4KEu4x7GRrCbSbjIGnXQJNT4R86X7VG92MBv3omGgj2EesEoqyebsAZyyx9 mEKJz7YhsmZ3N3KO0NZVAnpc2G+CH3wKW8S2YHFs1Ee0nBiVQ6RQ5qeFZPN1LV0r GUQEXKPXvxBPNVnnIBGL1D2EV/YmWMrAkR+HHj9PGVUbC1z3pxho3AtgMGAkysEJ XatPZk1gwQPB+7Qi5FLK1XfTYxjdY6BRHRtMvqJ6cqUj4Fh9JLRqg==
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-sender:x-me-sender:x-sasl-enc; s=fm1; bh=BXoCO4 vVlasemnenvSOGKq/XgRcEWsY6c29BHm2Mml4=; b=PpNv//4UsgoWadtZ9KQ1VV K+QlRWHEtINQYUS+yQc8FpVS/CAr4AgHhVTqDhpf1PVTnvdwkYZpAUqDrdtjfcJx wOEkdOKsDRG0Q0FeoAFTD5Y0BkW9v+lXkoOFHGP5dc3a3CWqOf2X6m+KZ+teGRSX 9gCelETq4/6sDy3GNoHjyke4XO+M5PPcMAfYfoiWyM3vSVTTp85yMnzrP/UijVlL ftXR482JTkkKSaefeWwuYe/99GlAMOiuwGTUqh+TCN92Xyhrt+h2jCpC45mouMa4 6rUkPg7nhurfuvymQU7EdFjToAPKB8vaZlB1FnC+pUE3peMD455xBJ03ayzLCEOw ==
X-ME-Sender: <xms:AsSKWSLrKw6mApJ2EIzZeCCsAg7JBg8AMHw5MslUDggPs5Y_oyKPig>
Received: by mailuser.nyi.internal (Postfix, from userid 99) id 98E21E223E; Wed, 9 Aug 2017 04:12:50 -0400 (EDT)
Message-Id: <1502266370.1509134.1067758664.41CAABFA@webmail.messagingengine.com>
From: Neil Jenkins <neilj@fastmailteam.com>
To: IETF JMAP Mailing List <jmap@ietf.org>
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Type: multipart/alternative; boundary="_----------=_150226637015091344"
X-Mailer: MessagingEngine.com Webmail Interface - ajax-f209590a
Date: Wed, 09 Aug 2017 18:12:50 +1000
In-Reply-To: <BF5DBECF-F4EC-4137-9B45-F6A777755459@neiljhaveri.com>
References: <20170808092341.GB1457@meili> <1502188117.322839.1066636392.362BFD31@webmail.messagingengine.com> <BF5DBECF-F4EC-4137-9B45-F6A777755459@neiljhaveri.com>
Archived-At: <https://mailarchive.ietf.org/arch/msg/jmap/p81GdcwtSjY-jDbwjODJlVPRBdI>
Subject: Re: [Jmap] Attachments and composing more complex MIME structures
X-BeenThere: jmap@ietf.org
X-Mailman-Version: 2.1.22
Precedence: list
List-Id: JSON Message Access Protocol <jmap.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/jmap>, <mailto:jmap-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/jmap/>
List-Post: <mailto:jmap@ietf.org>
List-Help: <mailto:jmap-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/jmap>, <mailto:jmap-request@ietf.org?subject=subscribe>
X-List-Received-Date: Wed, 09 Aug 2017 08:12:53 -0000

On Wed, 9 Aug 2017, at 04:17 AM, Neil Jhaveri wrote:
> Yeah, the Apple Mail clients have a preference to avoid sending
> text/html, unless strictly necessary by the content:
> (A) A philosophical preference that text/plain be used whenever
>     possible,> since it results in a neater and more overall compact message, without> the redundancy of including both a text/html part with a text/plain
> fallback alternative part.

Compactness is good, but with JMAP you can just upload the HTML part and
have the server generate a plain part so you're not saving over-the-wire
data on your bandwidth-constrained mobile anymore. It would really only
be for the server-to-server transmission, and I doubt that it would make
a significant difference.
> (B) Broken implementations in the wild that caused various small
>     support> issues. The Apple clients did change once to always sending
> text/html if> there are images, but reverted it in a software update. For instance,> some Japanese cell phone carriers couldn’t properly handle
> messages sent> to an MMS bridge e-mail address if an image wasn’t a top-level
> MIME part.
Interesting. I wonder whether that system is still relevant today? Given
other clients *don't* (usually) generate the multipart/mixed format,
this would presumably be seeing a lot of issues with emails sent from
e.g. Gmail.
> How do other people here feel about the preference for text/plain?

I believe that battle has been fought and lost. You can generate clean,
minimal HTML and it's the one way to get reasonable font wrapping
everywhere on mobile, including when quoting replies.
> I agree, I’d like to see if the API can remain as-is, and we detail in> the spec how servers should construct MIME. I’d be happy to help with> this part.

That would be great. :)

> There is also the uglier case of "inlined attachments" that cannot be> properly referenced by HTML tags, e.g.:
> [plain text]
> [zip attachment]
> [more plain text]
> 
> I think the Apple clients are the only ones that even support
> this in the> UI and make a multipart/mixed message out of it, but I’m not sure.

I don't believe I've seen one of them in the wild. I am now curious to
know what our client would make of it!
>  Does anybody know if any other major clients offer this kind of UX?

I'm not aware of any.

Neil.