Re: [Jmap] I-D Action: draft-ietf-jmap-sieve-02.txt

Ken Murchison <murch@fastmail.com> Thu, 19 November 2020 14:16 UTC

Return-Path: <murch@fastmail.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 D3AE53A105B for <jmap@ietfa.amsl.com>; Thu, 19 Nov 2020 06:16:26 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.098
X-Spam-Level:
X-Spam-Status: No, score=-2.098 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, NICE_REPLY_A=-0.001, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=fastmail.com header.b=IElSQA0Q; dkim=pass (2048-bit key) header.d=messagingengine.com header.b=RvBrkgxu
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 Fy69aI1iehB0 for <jmap@ietfa.amsl.com>; Thu, 19 Nov 2020 06:16:25 -0800 (PST)
Received: from wout2-smtp.messagingengine.com (wout2-smtp.messagingengine.com [64.147.123.25]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 602143A107F for <jmap@ietf.org>; Thu, 19 Nov 2020 06:15:58 -0800 (PST)
Received: from compute3.internal (compute3.nyi.internal [10.202.2.43]) by mailout.west.internal (Postfix) with ESMTP id DD5C1424 for <jmap@ietf.org>; Thu, 19 Nov 2020 09:15:56 -0500 (EST)
Received: from mailfrontend1 ([10.202.2.162]) by compute3.internal (MEProxy); Thu, 19 Nov 2020 09:15:57 -0500
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fastmail.com; h= subject:to:references:from:message-id:date:mime-version :in-reply-to:content-type:content-transfer-encoding; s=fm1; bh=a +QSpYISlXXI2jwYpwG/2b6QeO7iKO8t3db4iPRaTag=; b=IElSQA0QRM8Xy8USc yMhbMXWd5+0wabO2wa2bTTFeKn2YqE84joRbMtfY9UjCW4JSEIf1uaNGW6OOc6WL AXguCi86Cc8/wV4+jCOh7XsjoXzWDVtWoerfuslJzoKw+qu9RtQv5ixxIwbUwAt9 qO8gV9FzsAgkmUVKYg4sqZbDcFR9KBVuhTx/kl6Bpw4faltnnVFgwefl7hEL4TK9 Qr+X4N4XH7iDtKtr4tEFRCKvp8C77fe/mUpgwyCcTBCAqKtw7p7rvZ1GEpxf7T5O oOR9iNrEfZ2iaaOMMl3bHoqjfPjF9zRoifw1idfs3Yia3owtC2L6rDxGnxirc8jY QhfpQ==
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-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm1; bh=a+QSpYISlXXI2jwYpwG/2b6QeO7iKO8t3db4iPRaT ag=; b=RvBrkgxu6Ft50/Oi4mJWJW6ynVkgs7kcT7OjEbPcbp/PuUOwsU8Lw5mCB YbSoQA2XzN9GWKO7JBKtcgabHFYyezJYI7/mLNJ17fuzsbIe58ybW9Avt1Zw0KLS 2T3EnAYs4mp/PDllHMED5yc3ZMYJA5OADRcLJom81tXAHgYgMsgQ1eMZEqNlIAJJ u0G6Y/drhlDpj7ctlMV89wAxkdgY4qW+ojhanSw/8s6xM/soOHuEr5osfgEStv7G Y9eddYutIomJc4FxPumiKG4v04vA4NgS98EbGGGPXOckIUpbaptMBu87uW0aj0sd P5ljSoZyxFdZM737qT3UEa78c8ZAQ==
X-ME-Sender: <xms:HH62X0Y8ZKAUATLUTxSkuJOPzg7PAHS4q01Ef1A-qTAQF6dcYTXYig> <xme:HH62X_apUuWIb0glLXeaJ4JSnQ9pCwxBN6keb_-ROS9T1YoOMWATCJwIEYFCpPhRd VbfZiFCymTaBA>
X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedujedrudefjedgieduucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucenucfjughrpefuvfhfhffkffgfgggjtgfgsehtke ertddtfeejnecuhfhrohhmpefmvghnucfouhhrtghhihhsohhnuceomhhurhgthhesfhgr shhtmhgrihhlrdgtohhmqeenucggtffrrghtthgvrhhnpedvueetudegieffieetvdfhie dutedvgeejkeekudetvddvvdduteejvefghfdvkeenucffohhmrghinhepihgvthhfrdho rhhgnecukfhppeejgedrjeejrdekhedrvdehtdenucevlhhushhtvghrufhiiigvpedtne curfgrrhgrmhepmhgrihhlfhhrohhmpehmuhhrtghhsehfrghsthhmrghilhdrtghomh
X-ME-Proxy: <xmx:HH62X--5DePBeTNWeYS6cTrdwq_k06Xw_Rjq4n_OIhXUUXpjb5st0g> <xmx:HH62X-pQHPHBGUX7MeqLOrbs1i4duSEOAlXa6uRuhOWQz9_DJR0PIQ> <xmx:HH62X_pzvNlBXCfQsRhVssBMCgIN6dfU61q6P5vR8bpJXfDto5Fg8Q> <xmx:HH62X82pyaonY3qdsHx-SUzqi7i9x-OwWIFgna5qTNuhH6CyAjSTTQ>
Received: from [192.168.1.22] (cpe-74-77-85-250.buffalo.res.rr.com [74.77.85.250]) by mail.messagingengine.com (Postfix) with ESMTPA id 241823280063 for <jmap@ietf.org>; Thu, 19 Nov 2020 09:15:56 -0500 (EST)
To: jmap@ietf.org
References: <160431690732.22434.10293492942158194310@ietfa.amsl.com> <36838c43-aefb-c7f9-d973-2e6f8df5e78f@open-xchange.com>
From: Ken Murchison <murch@fastmail.com>
Message-ID: <bb04b849-024e-f07e-ea2d-e63e124cd8ab@fastmail.com>
Date: Thu, 19 Nov 2020 09:15:55 -0500
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.4.0
MIME-Version: 1.0
In-Reply-To: <36838c43-aefb-c7f9-d973-2e6f8df5e78f@open-xchange.com>
Content-Type: text/plain; charset="utf-8"; format="flowed"
Content-Transfer-Encoding: 8bit
Content-Language: en-US
Archived-At: <https://mailarchive.ietf.org/arch/msg/jmap/PD2NXzNol9_ZuvmE_rPP_UHFzVY>
Subject: Re: [Jmap] I-D Action: draft-ietf-jmap-sieve-02.txt
X-BeenThere: jmap@ietf.org
X-Mailman-Version: 2.1.29
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: Thu, 19 Nov 2020 14:16:32 -0000

Hi Stephan,


On 11/19/20 8:01 AM, Stephan Bosch wrote:
>
> First, I think this now misses a nice way to upload/download raw Sieve 
> scripts (i.e. without JSON string escaping). As said earlier in this 
> mailing list, using the blob upload/download facility would be better 
> and it is more consistent with jmap:mail in my opinion.


The reason that we chose to provide the content as an argument to /set, 
/validate, and /test (unless using scriptId) is to avoid the extra 
roundtrip of having to first upload the script in a separate request.

That said, a client could leverage 
https://tools.ietf.org/html/draft-gondwana-jmap-blob-01 
<https://tools.ietf.org/html/draft-gondwana-jmap-blob-01> to avoid the 
extra roundtrip, but I will note that in order to avoid JSON string 
escaping, the script would have to be base64-encoded.

I have no strong opinion either way on how the script content gets 
supplied for the /set method.  I'll leave that up to others to hash out.


What do you envision would be returned by /get?  The script content, or 
a blobId that would have to be subsequently fetched?


>
> Second, I remember RFC 5784 (https://tools.ietf.org/html/rfc5784). 
> That is an effort to map the Sieve language grammar to XML. We could 
> (optionally of course) do the same in this extension using JSON rather 
> than XML and make it easier for clients to evaluate, display, and 
> manipulate Sieve scripts without the need to write a Sieve 
> parser/generator. This could be a "content:as(json)" field, or 
> something like that. Or is that just too complex?


If someone wants come up with a design for a JSON object to represent 
Sieve, we could certainly consider it.  Again, I have no strong opinion.

-- 
Kenneth Murchison
Senior Software Developer
Fastmail US LLC