[imapext] AD review of draft-ietf-imapapnd-rfc2088bis-03

Barry Leiba <barryleiba@computer.org> Fri, 04 March 2016 23:03 UTC

Return-Path: <barryleiba@gmail.com>
X-Original-To: imapext@ietfa.amsl.com
Delivered-To: imapext@ietfa.amsl.com
Received: from localhost (ietfa.amsl.com [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 09D941ABD3B for <imapext@ietfa.amsl.com>; Fri, 4 Mar 2016 15:03:23 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.278
X-Spam-Level:
X-Spam-Status: No, score=-1.278 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, FM_FORGED_GMAIL=0.622, FREEMAIL_FROM=0.001, SPF_PASS=-0.001] autolearn=no
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 FnhCR6aTFZbV for <imapext@ietfa.amsl.com>; Fri, 4 Mar 2016 15:03:21 -0800 (PST)
Received: from mail-ig0-x22c.google.com (mail-ig0-x22c.google.com [IPv6:2607:f8b0:4001:c05::22c]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 86B581ABD38 for <imapext@ietf.org>; Fri, 4 Mar 2016 15:03:21 -0800 (PST)
Received: by mail-ig0-x22c.google.com with SMTP id hb3so6334285igb.0 for <imapext@ietf.org>; Fri, 04 Mar 2016 15:03:21 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:date:message-id:subject:from:to:cc; bh=U2d/rUw1wYPvhrquTKw0h0QUt9pU+gpGz1iyUZ8egBE=; b=H587KrNuL92eT+hqKRHq9CkQWNd/vQtpVCe78rYlJQ84P2rWGL6ce/SdiypP+q30yJ 0gEBpV5s2juknryxc8ue0CHwRU7knM4XoIefUo1GbBw6pj5yJEDngaaOeYvXmK2ekWZG yOuzGvaipgN6x6ow3uy3PUCQX7QpUHUMBe6zGwkkoyIOdI2QlLj9ywm0XADcL4u81i6L x1mxNRJ7H1zjNl3jD435cF3ESCnXkn0MH1FxUUT2CSUb6nXH+9wgmzJ6EMu/ZRRjGgGy L4+OVDDIFqG5o+pusUqqcDri0ORv4oAtkPuhwIbrjPiJo6hFD93Y21nj13VjJAtcNW5M 1Xig==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:sender:date:message-id:subject:from :to:cc; bh=U2d/rUw1wYPvhrquTKw0h0QUt9pU+gpGz1iyUZ8egBE=; b=QSG6g1QAddY89/8nFjAzLwmRSqEIA2CknLhAVg2bkXwuPHGrxOIKyRan0eu8iz6Bx3 xjtyBGq/BNh7cZYTgoSwet/2BwgOSlcytZN75ic6ObFtRNEQI2lwRqaUo7EmtT/Logks Hz0jlmYnofMppmOBSGXJFQitpIYD7LWNU86/9IywND4f+kSXMiFUcyA1qfOrPK/13gVW b2jM5QIam2NUJ4M9iEVAfKXc3ZKtFGc6W211zQGuH7Cw48MEqmRuD+s5ACxSZxajju8P XVaW5oBK85Mi077BCShh7X81Vx9aNuhgjqw95DpTXeENbqBTTHlRh0y1wz276PSfLHpc QtuQ==
X-Gm-Message-State: AD7BkJKCwr02bkbyn2ypYpddWzbZP8ci3UaGVhRitEklPZWjKM2BCtO2In9e5IKVX4XUnmMTubxxPaj+2QdPwQ==
MIME-Version: 1.0
X-Received: by 10.50.124.41 with SMTP id mf9mr1474825igb.53.1457132600921; Fri, 04 Mar 2016 15:03:20 -0800 (PST)
Sender: barryleiba@gmail.com
Received: by 10.36.59.133 with HTTP; Fri, 4 Mar 2016 15:03:20 -0800 (PST)
Date: Fri, 04 Mar 2016 18:03:20 -0500
X-Google-Sender-Auth: KC3DKk2bz48hPqj-I-i2YODd37s
Message-ID: <CALaySJJxkYW+w1wY7NNH73P5qXoxutYz2VeM4E23BG0U_U5p5g@mail.gmail.com>
From: Barry Leiba <barryleiba@computer.org>
To: Alexey Melnikov <aamelnikov@fastmail.fm>
Content-Type: text/plain; charset="UTF-8"
Archived-At: <http://mailarchive.ietf.org/arch/msg/imapext/-M65bBuDT5GFRS0M1RbR6TIQ0ns>
Cc: "imapext@ietf.org" <imapext@ietf.org>
Subject: [imapext] AD review of draft-ietf-imapapnd-rfc2088bis-03
X-BeenThere: imapext@ietf.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: Discussion of IMAP extensions <imapext.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/imapext>, <mailto:imapext-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/imapext/>
List-Post: <mailto:imapext@ietf.org>
List-Help: <mailto:imapext-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/imapext>, <mailto:imapext-request@ietf.org?subject=subscribe>
X-List-Received-Date: Fri, 04 Mar 2016 23:03:23 -0000

Here's my review of draft-ietf-imapapnd-rfc2088bis-03.  Much of this
is editorial, but there are a couple of substantive things here.

-- Introduction --

"(RFC 3501)" should be a citation, "[RFC3501]".  (And then you can
remove the citation at the beginning of Section 3, if you like (or
leave it, if you prefer).)

-- Section 3 --

   If the server does
   not advertise either of the above capabilities, the client must use
   synchronizing literals instead.

Minor point, but I'd word this like this (because I find "instead" to
be a bit inapt):

NEW
   If the server does
   not advertise either of the above capabilities, the client can only
   use synchronizing literals.
END

   The protocol receiver of an IMAP server must check the end of every
   received line

That "must" should probably be "MUST".

We probably should also take this opportunity to fix a bit of
confusion that's come up with respect to this paragraph in the past.
How about this?:

OLD
   The protocol receiver of an IMAP server must check the end of every
   received line (a sequence of octets that end with a CRLF) for an open
   brace ('{') followed by an octet count, a plus ('+'), and a close
   brace ('}') immediately preceeding the CRLF.  If it finds this
   sequence, it is the octet count of a non-synchronizing literal and
   the server MUST treat the specified number of following octets and
   the following line as part of the same command.  A server MAY still
   process commands and reject errors on a line-by-line basis, as long
   as it checks for non-synchronizing literals at the end of each line.

NEW
   The protocol receiver of an IMAP server MUST check the end of every
   received line (a sequence of octets that ends with a CRLF) for an
   open brace ('{') followed by an octet count, a plus ('+'), and a
   close brace ('}') immediately preceeding the CRLF.  If it finds this
   sequence, it is the octet count of a non-synchronizing literal and
   the server MUST treat the specified number of following octets and
   the following octets through the next CRLF as part of the same
   command.

   It's important to note that the literal is not delimited by CRLF.
   It ends after the number of bytes specified by the octet count, and
   the current command continues from there.  There might be a CRLF
   immediately after, which ends the command.  Or there might be more
   octets, specifying other command parameters, before the CRLF.  If
   a SPACE character is needed between parameters, it's important that
   the SPACE appear after the literal, in its appropriate place.

   A server MAY still process commands and reject errors on a
   line-by-line basis, as long as it checks for non-synchronizing
   literals at the end of each line.

END

...and...

OLD
  Example:

   C: A001 LOGIN {11+}
   C: FRED FOOBAR {7+}
   C: fat man
   S: A001 OK LOGIN completed

NEW
   Example:

   C: A001 LOGIN {11+}
   C: FRED FOOBAR {7+}
   C: fat man
   S: A001 OK LOGIN completed

   This is semantically equivalent to this version that uses quoted
   strings instead of literals:

   C: A001 LOGIN "FRED FOOBAR" "fat man"
   S: A001 OK LOGIN completed

   Note that the SPACE after FOOBAR in the first version corresponds
   to the SPACE between the two quoted strings in the second.
END

I used to get questions from implementors about the CRLF and SPACE
things.  If you really think this is unnecessary, feel free to opt out
of this suggestion.

-- Section 4 --

   a compliant LITERAL+ server
   implementation has to make a choice between several non-optimal
   choices:

There are only two choices, and in no one's reckoning does two count
as "several".  Maybe change "several" to "two"?

In bullet 1:

       (The server is allowed to send the tagged BAD/NO response before
       reading the whole non-synchronizing literal.)

Substantive: Shouldn't that be "the server is not allowed" (missing "not")?

Please change "most of commands" to "most commands".

"Denial Of Service attacks" shouldn't be capitalized, but should be
hyphenated; make it "denial-of-service attacks" (and similarly, remove
the capitals in Section 9).

-- Section 5 --
Substantive: Shouldn't references to "APPEND" be removed from here,
since we re-spun LITERAL- as applying to all commands?  Also, the last
sentence doesn't really make sense.  In order to reject the command
with BAD and TOOBIG, the server has to read (and discard) the literal
-- that is, it's already processing according to bullet 1 in Section
4.

So:

OLD
   The "LITERAL-" extension is almost identical to "LITERAL+", with one
   exception: when "LITERAL-" is advertised, non-synchronizing literals
   used in any command MUST NOT be larger than 4096 bytes.  Any literal
   larger than 4096 bytes MUST be sent as an RFC 3501 synchronizing
   literal.  A "LITERAL-" compliant server that encounters a non-
   synchronizing literal in APPEND larger than 4096 bytes MUST reject
   such APPEND command with a tagged BAD response that contains the
   TOOBIG response code [RFC4469].  It then MAY proceed as described in
   Section 4.

NEW
   The "LITERAL-" extension is almost identical to "LITERAL+", with one
   exception: when "LITERAL-" is advertised, non-synchronizing literals
   used in any command MUST NOT be larger than 4096 bytes.  Any literal
   larger than 4096 bytes MUST be sent as an RFC 3501 synchronizing
   literal.  A "LITERAL-" compliant server that encounters a non-
   synchronizing literal larger than 4096 bytes MUST read (and discard)
   the literal, and then reject the command with a tagged BAD response
   that contains the TOOBIG response code [RFC4469].

END

Substantive: I also suggest adding this paragraph, to make things
perfectly clear:

INSERT
   Note that the form of the non-synchronizing literal does not change:
   it still uses the "+" in the literal itself, even if the applicable
   extension is "LITERAL-".
END

-- Section 9 --

   Section 4 motivates creation of the "LITERAL-" extension
   that partially improves the situation.

I would just say 'The "LITERAL-" extension partially improved this situation.'

-- Section 10 --

OLD
   This document requests that IANA updates the above registry to
   include the entry for LITERAL+ capability pointing to this document.

NEW
   This document requests that IANA update the above registry to
   replace the reference for LITERAL+ to point to this document.

END

(And as a nit, change "adds" to "add" in the next paragraph; it should
be subjunctive mood.)

-- 
Barry, ART Director