Re: [core] I-D Action: draft-ietf-core-stateless-02.txt

Klaus Hartke <hartke@projectcool.de> Tue, 22 October 2019 11:08 UTC

Return-Path: <hartke@projectcool.de>
X-Original-To: core@ietfa.amsl.com
Delivered-To: core@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id C465312080A for <core@ietfa.amsl.com>; Tue, 22 Oct 2019 04:08:03 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.9
X-Spam-Level:
X-Spam-Status: No, score=-1.9 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001] autolearn=ham autolearn_force=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 tQi6Dl7SzsPT for <core@ietfa.amsl.com>; Tue, 22 Oct 2019 04:08:00 -0700 (PDT)
Received: from wp382.webpack.hosteurope.de (wp382.webpack.hosteurope.de [IPv6:2a01:488:42:1000:50ed:8597::]) (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 A157C120241 for <core@ietf.org>; Tue, 22 Oct 2019 04:08:00 -0700 (PDT)
Received: from mail-qt1-f178.google.com ([209.85.160.178]); authenticated by wp382.webpack.hosteurope.de running ExIM with esmtpsa (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) id 1iMs18-0006qG-An; Tue, 22 Oct 2019 13:07:58 +0200
Received: by mail-qt1-f178.google.com with SMTP id z22so5581907qtq.11 for <core@ietf.org>; Tue, 22 Oct 2019 04:07:58 -0700 (PDT)
X-Gm-Message-State: APjAAAW66ReRkfFFL7w26W3CP9fwHYmOqJBP7JDULYmVtUn5M+d4AEYN Cp56norSVrr7ULPvL4/4kkF0aC75W6QABL8ctVU=
X-Google-Smtp-Source: APXvYqx9BMfTbfWlqH2S3wecDONR5MDnC2iMJ6hk34oOwj9z1ZRlcEU2ZVrBLJ2sLo7Ea13mLGs1kzkWS6TwDVOn4xk=
X-Received: by 2002:ac8:b42:: with SMTP id m2mr2619510qti.174.1571742477285; Tue, 22 Oct 2019 04:07:57 -0700 (PDT)
MIME-Version: 1.0
References: <157167881320.31820.15335648329568633649@ietfa.amsl.com> <CAAzbHvZB4ZUEhgVujwHOE3fum0JLQUu8vYyiBVhGDH5KfsEuxA@mail.gmail.com> <32E81F88-6171-4EBB-AA6E-886CF5F59548@arm.com> <CAAzbHva-v_EWGSbYWnio=7oNn=sAvQADRj4zTV5E7sYYMxdU0g@mail.gmail.com> <38629887-0795-4F7F-B6AB-E446B63489CF@arm.com>
In-Reply-To: <38629887-0795-4F7F-B6AB-E446B63489CF@arm.com>
From: Klaus Hartke <hartke@projectcool.de>
Date: Tue, 22 Oct 2019 13:07:21 +0200
X-Gmail-Original-Message-ID: <CAAzbHvYGk_DrAn5gyoO5-TSqwRR4B107u7szdRNXjKycRSt0_Q@mail.gmail.com>
Message-ID: <CAAzbHvYGk_DrAn5gyoO5-TSqwRR4B107u7szdRNXjKycRSt0_Q@mail.gmail.com>
To: Thomas Fossati <Thomas.Fossati@arm.com>
Cc: "core@ietf.org WG" <core@ietf.org>
Content-Type: text/plain; charset="UTF-8"
X-bounce-key: webpack.hosteurope.de; hartke@projectcool.de; 1571742480; 2f6376f5;
X-HE-SMSGID: 1iMs18-0006qG-An
Archived-At: <https://mailarchive.ietf.org/arch/msg/core/TdJ2SCVj3GxKs5sVBBSCvWlOSo4>
Subject: Re: [core] I-D Action: draft-ietf-core-stateless-02.txt
X-BeenThere: core@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: "Constrained RESTful Environments \(CoRE\) Working Group list" <core.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/core>, <mailto:core-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/core/>
List-Post: <mailto:core@ietf.org>
List-Help: <mailto:core-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/core>, <mailto:core-request@ietf.org?subject=subscribe>
X-List-Received-Date: Tue, 22 Oct 2019 11:08:04 -0000

Thomas Fossati wrote:
> > The intention was to say: If the value is less than 8, then it shall
> > be set to 8. If it's greater than 65804, then it shall be set to
> > 65804. I though that's what clamping means, no?
>
> Sure, it's not "clamp" but the following "to be *within* this range"
> that creates the ambiguity.

So maybe just this?

            The option value MUST NOT be less than 8 or greater than 65804. When
            an option value outside this range is received, the value MUST be
            clamped to this range.

(I'm not a native speaker; help is appreciated.)

> Thanks.  This is exactly what I meant by "dense": it looks like there is
> an interesting amount of relevant information that is left implicit.  I
> think articulating the assumptions as you just did will make it easier
> on future readers.
>
> [...]
>
> The latter looks like a 4.xx to me.

Like so?

   If a server supports extended token lengths but receives a request
   with a token of a length it is unwilling or unable to handle, it MUST
   NOT reject the message, as that would imply that extended token
   lengths are not supported at all.  Instead, if the condition is
   temporary, it SHOULD return a 5.03 (Service Unavailable) response.
   If the condition is permanent, it SHOULD return a 4.00 (Bad Request)
   response.

   Design Note:  The requirement to return an error response when a
      request cannot be handled might seem somewhat contradictory.
      However, handling a request usually involves a number of steps
      from receiving the message to handing it over to application
      logic.  The idea is that a server implementing this document at
      least should support large tokens in the first few steps (enough
      to return an error response rather than a Reset message).

Klaus