Re: [Cbor] draft-ietf-cbor-cddl-control-00 should add CDDL notation for CBOR Sequences

Henk Birkholz <henk.birkholz@sit.fraunhofer.de> Thu, 05 November 2020 16:06 UTC

Return-Path: <henk.birkholz@sit.fraunhofer.de>
X-Original-To: cbor@ietfa.amsl.com
Delivered-To: cbor@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id A46A33A1410 for <cbor@ietfa.amsl.com>; Thu, 5 Nov 2020 08:06:01 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.146
X-Spam-Level:
X-Spam-Status: No, score=-2.146 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, NICE_REPLY_A=-0.247, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=unavailable 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 oFIyO2vStlAH for <cbor@ietfa.amsl.com>; Thu, 5 Nov 2020 08:05:58 -0800 (PST)
Received: from mail-edgeKA27.fraunhofer.de (mail-edgeka27.fraunhofer.de [153.96.1.27]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 588553A142C for <cbor@ietf.org>; Thu, 5 Nov 2020 08:05:56 -0800 (PST)
X-IronPort-Anti-Spam-Filtered: true
X-IronPort-Anti-Spam-Result: A2GNBgCjIaRf/xoBYJliHAEBAQEBAQcBARIBAQQEAQFAgU+EUAqEM5BxLpwpCwEBAQEBAQEBAQcBAS0CBAEBhEoCghABJTgTAhABAQYBAQEBAQYEAgKGIQYzhlABBSMPAQVBEAkCDgoCAiYCAkcQBgEMAQUCAQGDIoJ8BZROnAWBMoVXgy6BQoEOKoZjhlcPgU0/gREnD4JcPoJdBIR0gl8Ek2CkFisHgWOBDYEQBAuZXgUKH5JHBo8gk02gRAIEAgkCFYFrgXtNJIM4UBcCDYZOh10XFI4TcwIBNQIGAQkBAQMJfIw7AYEQAQE
X-IPAS-Result: A2GNBgCjIaRf/xoBYJliHAEBAQEBAQcBARIBAQQEAQFAgU+EUAqEM5BxLpwpCwEBAQEBAQEBAQcBAS0CBAEBhEoCghABJTgTAhABAQYBAQEBAQYEAgKGIQYzhlABBSMPAQVBEAkCDgoCAiYCAkcQBgEMAQUCAQGDIoJ8BZROnAWBMoVXgy6BQoEOKoZjhlcPgU0/gREnD4JcPoJdBIR0gl8Ek2CkFisHgWOBDYEQBAuZXgUKH5JHBo8gk02gRAIEAgkCFYFrgXtNJIM4UBcCDYZOh10XFI4TcwIBNQIGAQkBAQMJfIw7AYEQAQE
X-IronPort-AV: E=Sophos;i="5.77,453,1596492000"; d="scan'208";a="25490899"
Received: from mail-mtaka26.fraunhofer.de ([153.96.1.26]) by mail-edgeKA27.fraunhofer.de with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 05 Nov 2020 17:05:52 +0100
X-IronPort-Anti-Spam-Filtered: true
X-IronPort-Anti-Spam-Result: A0ApBQDvIaRf/1lIDI1iHAEBAQEBAQcBARIBAQQEAQFAgU+CKoFIMC4KhDOQcS6cKQsBAwEBAQEBBwEBLQIEAQGESgKCDgIlOBMCEAEBBQEBAQIBBgRxhTQGM4VzAQUjDwEFQRAJAg4KAgImAgJHEAYBDAEFAgEBgyKDAZROnAWBMoVXgy6BQoEOKoZjhlcPgU0/gREnD4JcPoJdBIR0gl8Ek2CkFisHgWOBDYEQBAuZXgUKH5JHBo8gk02gRAIEAgkCFYFrI4FXTSSDOFAXAg2GToddFxSOE0IxAgE1AgYBCQEBAwl8jDsBgRABAQ
X-IronPort-AV: E=Sophos;i="5.77,453,1596492000"; d="scan'208";a="95126370"
Received: from mailext.sit.fraunhofer.de ([141.12.72.89]) by mail-mtaKA26.fraunhofer.de with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 05 Nov 2020 17:05:50 +0100
Received: from mail.sit.fraunhofer.de (mail.sit.fraunhofer.de [141.12.84.171]) by mailext.sit.fraunhofer.de (8.15.2/8.15.2/Debian-10) with ESMTPS id 0A5G5oWe027164 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA256 bits=128 verify=NOT); Thu, 5 Nov 2020 17:05:50 +0100
Received: from [192.168.16.50] (79.234.121.161) by mail.sit.fraunhofer.de (141.12.84.171) with Microsoft SMTP Server (TLS) id 14.3.487.0; Thu, 5 Nov 2020 17:05:45 +0100
To: Carsten Bormann <cabo@tzi.org>, John Mattsson <john.mattsson=40ericsson.com@dmarc.ietf.org>
CC: "cbor@ietf.org" <cbor@ietf.org>
References: <317AB3AB-B1E9-4AD9-911E-559D166E2788@ericsson.com> <d45672c4-b42c-fb0f-3ab5-0fcd7712f29b@sit.fraunhofer.de> <FCE40691-EC98-4A0C-9C3E-59F9018A15C8@ericsson.com> <3f63613d-9571-f739-d517-042b4ca9398d@sit.fraunhofer.de> <B63CB2BF-1F68-4ECB-851B-CD794D1203D9@ericsson.com> <CB29760A-1F2F-464B-9DEB-5383130B554C@tzi.org>
From: Henk Birkholz <henk.birkholz@sit.fraunhofer.de>
Message-ID: <49921e68-b22b-0dfb-71a4-a1ae4f578c88@sit.fraunhofer.de>
Date: Thu, 05 Nov 2020 17:05:44 +0100
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0
MIME-Version: 1.0
In-Reply-To: <CB29760A-1F2F-464B-9DEB-5383130B554C@tzi.org>
Content-Type: text/plain; charset="utf-8"; format="flowed"
Content-Language: en-US
Content-Transfer-Encoding: 8bit
X-Originating-IP: [79.234.121.161]
Archived-At: <https://mailarchive.ietf.org/arch/msg/cbor/1-rz7QS8_k4pT94gaXtYEGMwAGM>
Subject: Re: [Cbor] draft-ietf-cbor-cddl-control-00 should add CDDL notation for CBOR Sequences
X-BeenThere: cbor@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: "Concise Binary Object Representation \(CBOR\)" <cbor.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/cbor>, <mailto:cbor-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/cbor/>
List-Post: <mailto:cbor@ietf.org>
List-Help: <mailto:cbor-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/cbor>, <mailto:cbor-request@ietf.org?subject=subscribe>
X-List-Received-Date: Thu, 05 Nov 2020 16:06:02 -0000

Or what Carsten said :-) Sry for just sending before checking!

On 05.11.20 16:46, Carsten Bormann wrote:
> On 2020-11-05, at 16:10, John Mattsson <john.mattsson=40ericsson.com@dmarc.ietf.org> wrote:
>>
>> All the document I cited use unadorned CBOR Sequences (i.e. not wrapped in a byte string). As far as I know there is no way to write CDDL that matches the unadorned CBOR Sequence 0x0102 ( 1, 2 ). I think this needs to be fixed.
> 
> Citing RFC 8742 Section 4.1:
> 
>     Currently, CDDL does not provide for unadorned CBOR Sequences as a
>     top-level subject of a specification.  For now, the suggestion is to
>     use an array for the top-level rule, as is used for the ".cborseq"
>     control operator, and add English text that explains that the
>     specification is really about a CBOR Sequence with the elements of
>     the array:
> 
>     ; This defines an array, the elements of which are to be used
>     ; in a CBOR Sequence:
>     my-sequence = [* my-element]
>     my-element = my-foo / my-bar
> 
>     (Future versions of CDDL may provide a notation for top-level CBOR
>     Sequences, e.g., by using a group as the top-level rule in a CDDL
>     specification.)
> 
> Are you talking about the “future versions” part of that?
> 
> Grüße, Carsten
>