Re: [Cbor] [art] Artart early review of draft-ietf-cbor-file-magic-02 Thu, 26 August 2021 03:11 UTC

Return-Path: <>
Received: from localhost (localhost []) by (Postfix) with ESMTP id 699333A10F5 for <>; Wed, 25 Aug 2021 20:11:50 -0700 (PDT)
X-Virus-Scanned: amavisd-new at
X-Spam-Flag: NO
X-Spam-Score: -1.897
X-Spam-Status: No, score=-1.897 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, SPF_HELO_NONE=0.001, SPF_NONE=0.001, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no
Authentication-Results: (amavisd-new); dkim=pass (2048-bit key)
Received: from ([]) by localhost ( []) (amavisd-new, port 10024) with ESMTP id OoAbjIklQNdg for <>; Wed, 25 Aug 2021 20:11:45 -0700 (PDT)
Received: from ( [IPv6:2001:558:fe21:29:69:252:207:37]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by (Postfix) with ESMTPS id 36CF63A10EE for <>; Wed, 25 Aug 2021 20:11:44 -0700 (PDT)
Received: from ([]) by with ESMTP id J5ilmiik7K3eXJ5nqmBoEX; Thu, 26 Aug 2021 03:11:42 +0000
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;; s=20180828_2048; t=1629947502; bh=gj1gjgKeN5pSyLPavarGCwSNqkCCd6EKSKXGVgw1erk=; h=Received:Received:Received:Received:From:To:Subject:Date: Message-ID; b=YRcGoGO8LvxuKcyCz97+kzIO3M7ep4fM6DdI8O6Vnfa2PW0UbVGge9X2bn1xIkPLn e+rNDvwenAC8/ol4vb132OZXf3MeV6Q5Co/zjdrioXF4iG/ZJFVuBXauMNLdCVQnrV CeAu9SYqEUDvlCnZKqtE1IdGhGmalxsvhu+RMANtkWVF5DQH5w4reZLGHEDAQS2vPK QoXELcuPaFFvmf765zo+nkeUHrimLkxt37KlrEDeaCNkiuR5I9O2TvcvtHVM6+STHG A70p/2RUJgGoeGJbjafszTtjVjCnPHhYQEjKuMpSJr52DzNsZzn4/JlS3Vg7apz+4z lTT74xyXB6d1g==
Received: from ([IPv6:2601:192:4a00:430::327]) by with ESMTPA id J5nom00LlkJw7J5npmH8F7; Thu, 26 Aug 2021 03:11:42 +0000
X-Xfinity-VMeta: sc=-100.00;st=legit
Received: from (localhost []) by (8.16.1/8.16.1) with ESMTPS id 17Q3BemW009401 (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384 bits=256 verify=NOT); Wed, 25 Aug 2021 23:11:40 -0400
Received: (from worley@localhost) by (8.16.1/8.16.1/Submit) id 17Q3BdSw009398; Wed, 25 Aug 2021 23:11:39 -0400
From: (Dale R. Worley)
To: Bernard Aboba <>
In-Reply-To: <> (
Sender: (Dale R. Worley)
Date: Wed, 25 Aug 2021 23:11:39 -0400
Message-ID: <>
Archived-At: <>
Subject: Re: [Cbor] [art] Artart early review of draft-ietf-cbor-file-magic-02
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: "Concise Binary Object Representation \(CBOR\)" <>
List-Unsubscribe: <>, <>
List-Archive: <>
List-Post: <>
List-Help: <>
List-Subscribe: <>, <>
X-List-Received-Date: Thu, 26 Aug 2021 03:11:51 -0000

There's an odd characteristic about this document, not in its content,
but in its style.  It's written as a proposal (a word which is used
several times), and yet it's intended to be a BCP, which tells people
what do to.  And various passages are written as if the reader is a
co-designer.  For instance,

   A magic number is ideally a unique fingerprint, present in the first
   4 or 8 bytes of the file, which does not change when the contents
   change, and does not depend upon the length of the file.

(Though it would be more accurate to say, "... present at a defined
location in the first few bytes of the file ...".)  If this was a
specification, it would say essentially the same fact as "This scheme
has the desired property of magic numbers of having a unique fingerprint
at a fixed location near the beginning of the data."

I get the sense that the authors are ambivalent whether they are saying
what implementers should do, or just floating an idea.  Though I don't
know if that is accurate.

As far as content goes, I favor the "tag wrapped" version over the "tag
sequence", as it has assured upward-compatibility (if the implementation
follows the requirement to ignore unknown tags).  In particular, if the
data consists of a sequence of CBOR items, each one could be tagged (if
they might differ) or only the first one be tagged (if they don't).  But
that's a different matter.