[Cbor] Re: Working Group Last Call on Serialization draft
Laurence Lundblade <lgl@island-resort.com> Wed, 23 September 2026 17:17 UTC
Received: from sender4-pp-f112.zoho.com (sender4-pp-f112.zoho.com [136.143.188.112]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by mx.ietf.org (Postfix) with ESMTPS id 5A2EE31 for <cbor@ietf.org>; Wed, 23 Sep 2026 17:17:58 +0000 (UTC)
Authentication-Results: mx.ietf.org; dkim=none ("invalid DKIM record") header.d=island-resort.com header.s=island header.b=Rr3BWxdy; arc=pass ("zohomail.com:s=zohoarc:i=1"); dmarc=none; spf=pass (mx.ietf.org: domain of lgl@island-resort.com designates 136.143.188.112 as permitted sender) smtp.mailfrom=lgl@island-resort.com
ARC-Seal: i=1; a=rsa-sha256; t=1790183865; cv=none; d=zohomail.com; s=zohoarc; b=fTwpXH6BPzdWVFwdafxSzSh2R0yuWY75Hwglm7W8YZYGK8BV63B6tXE9r+E5fPZhx8jkNfctqH8mQVoP0B070vDO7zG1ASP4cnnUd1FM26rO9nzt+pGUBToF4XwtjFuaB2BzyGHFv1VjiOuUCr/SekIv6GWdntCWT8VzsPMG7G8=
ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1790183865; h=Content-Type:Cc:Cc:Date:Date:From:From:In-Reply-To:MIME-Version:Message-ID:Subject:Subject:To:To:Message-Id:Reply-To; bh=uyYaciE2gIJ4uES0Hs3aHdvpUhbEU+wH56i+pgAnP9Q=; b=Gw/F/tUxlE5Y5Rn9X3HQwgN+fav3aM6+UwJpSsA3WEEUJCPHhbimWk3oQszWq9FF05dws7F0UK37BChj3Z4Pnno1R7eJeSAzLEx1Cbs1sZ4hLAnVct9IdjmQo+53YLYe6nAkYi28MTmgrD+5lCWh0yF2qorBwKGBBFM8F6Kqe0o=
ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass header.i=island-resort.com; spf=pass smtp.mailfrom=lgl@island-resort.com; dmarc=pass header.from=<lgl@island-resort.com>
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; t=1790183865; s=island; d=island-resort.com; i=lgl@island-resort.com; h=From:From:Message-Id:Message-Id:Content-Type:Mime-Version:Subject:Subject:Date:Date:In-Reply-To:Cc:Cc:To:To:Reply-To; bh=uyYaciE2gIJ4uES0Hs3aHdvpUhbEU+wH56i+pgAnP9Q=; b=Rr3BWxdyDGzMPcqWVCuY4PrhF1NIFEd5QxNAXslYE4j9yWLOnmXcwK/eFtb8D0dq GZ29M8pqEW4+MxWekn5I6vSAi70tZc7u5d4mjNmCf5ULNkiLBbTihry5L4YGUa8er7b cYlbes3CbIyM6RtYNsxftFUQ6YAKbMCi5C9ChQxE=
Received: by smtp.zohomail.com with SMTPS id 17901838625141001.1161589085034; Wed, 23 Sep 2026 10:17:42 -0700 (PDT)
From: Laurence Lundblade <lgl@island-resort.com>
Message-Id: <3D27E0ED-A34E-4AEF-A126-4DE556400EC5@island-resort.com>
Content-Type: multipart/alternative; boundary="Apple-Mail=_B10A524E-4714-41B8-ACEF-63113231E265"
Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3826.700.81.1.8\))
Date: Wed, 23 Sep 2026 10:17:31 -0700
In-Reply-To: <876653A4-6425-45E1-A77A-F0A6A1315BDD@cursive.net>
To: Joe Hildebrand <hildjj@cursive.net>
References: <CALaySJJa=QjUM5B6d8boiFb8qyRwf6LO32WVVWBGuCWtSmEFCQ@mail.gmail.com> <876653A4-6425-45E1-A77A-F0A6A1315BDD@cursive.net>
X-Mailer: Apple Mail (2.3826.700.81.1.8)
X-ZohoMailClient: External
X-Spamd-Bar: /
Message-ID-Hash: CRCYD6355J6UFJI3WVANKRTOCESAP3XI
X-Message-ID-Hash: CRCYD6355J6UFJI3WVANKRTOCESAP3XI
X-MailFrom: lgl@island-resort.com
X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; loop; banned-address; header-match-cbor.ietf.org-0; emergency; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header
CC: Barry Leiba <barryleiba@gmail.com>, CBOR Working Group <cbor@ietf.org>
X-Mailman-Version: 3.3.10
Precedence: list
Subject: [Cbor] Re: Working Group Last Call on Serialization draft
List-Id: "Concise Binary Object Representation (CBOR)" <cbor.ietf.org>
Archived-At: <https://mailarchive.ietf.org/arch/msg/cbor/YhDTOz1hkH43fCEMcVPu4RJgLzs>
List-Archive: <https://mailarchive.ietf.org/arch/browse/cbor>
List-Help: <mailto:cbor-request@ietf.org?subject=help>
List-Owner: <mailto:cbor-owner@ietf.org>
List-Post: <mailto:cbor@ietf.org>
List-Subscribe: <mailto:cbor-join@ietf.org>
List-Unsubscribe: <mailto:cbor-leave@ietf.org>
I’ve responded to everything except the comments about map sorting in section 5. I have a plan to address them. This has resulted in lots of good improvements to the document. LL [editor’s draft]: https://cbor-wg.github.io/draft-ietf-cbor-serialization/draft-ietf-cbor-serialization.html [diff]: https://author-tools.ietf.org/api/iddiff?doc_1=draft-ietf-cbor-serialization&url_2=https://cbor-wg.github.io/draft-ietf-cbor-serialization/draft-ietf-cbor-serialization.txt > On Aug 18, 2026, at 12:05 PM, Joe Hildebrand <hildjj@cursive.net> wrote: > > Overall: I support publishing this document. It needs to be a lot more clear about the difference between encoding in a given serialization and erroring on decode when an expected serialization is not found. There are notes we could add: > > - (most important) Make it clear in each section whether the rules apply to encoders or decoders. I have made improvements to section 2. > - Make it clear that it is up to the protocol designer what to do when decoding inputs that are not in the expected encoding. This is good for protocols where encoding errors (attacks?) might have security consequences. A couple of examples or criteria could help protocol designers decide. There is some text in appendix H but it isn't directive enough. Protocol designers or protocol and CBOR library implementors? I improved the appendix and I have it moon lighting as a security consideration for well-formedness checking, the pimary defense against malicious input. > - Make a note that even if the protocol designer did not specify that checking should be done, it may make sense to check on inputs on non-constrained devices to increase the likelihood of finding encoding errors before crashing constrained devices. I went the other way and empahsized that decoders must not rely on checking decoders for well-formedness checking. > Other issues: > > s1: nit. it was weird to have to read an appendix before finishing the first paragraph. Perhaps the BLUF (bottom line up front) approach might work, where the second sentence could reference the information model/data model/serialization layers so that I could put off reading the appendix until later? I promoted the appendix > s1: nit. should table 1 include an example or two that are not in preferred serialization? For example, if you have a small encoder that sends integers as 1+4 bytes, that meets the "constraints and requirements of a particular environment" requirement. That would mean that there might need to be a newly-inserted s1.1 that says that STD94 defines preferred serialization, perhaps with the title "Minimizing size on the wire". It would also mean that the current s1.3 would need a few tweaks. In the intro, I want to make the point simply and clearly that CBOR serialization is variable and thus needs prefp and detrm. A table of two is a enough and pops out nicely I think. We can do this with integers of variable lengths which would align with 8949 preferred instead of def/indef lengths, but I’m inclined to leave it as is. > s1.3: nit. title is RFC 8949, and text is STD94. Either those should be the same, or there should be text that states inline that STD94 is RFC 8949, for those that don't have the numbers memorized. No longer refer to STD94 at all. > s2.1.1: I suggest "it may mandate deterministic serialization for all implementations in order to eliminate all serialization variability" -> "it may mandate deterministic serialization for all implementations in order to minimize serialization variability", since there are other sources of serialization variability. Since the outlier was UTF-8, I’ve addressed this in the appendix on general considerations for serialization. > s2.1.2: nit: obligatory objection to "bake-off" due to trademark issues, perhaps just remove the parenthetical? Reworded > s2.1.2: "The strategy most highly RECOMMENDED is to normatively require preferred-plus serialization" for encoders, I assume? Are we recommending that decoders should error if they receive non preferred-plus? I would expect only certain protocols to need that. I’ve clarified that implementing preferred-plus decoding means accepting everything that is preferred-plus, but not to the exclusion of other well-formed. > s2.1.2: "A CBOR library may choose to implement only deterministic serialization" again, for encoding? > > s2.2.2: Same issue. For encoding? > > s2.2.3: Same issue. For encoding? Reworded section 2 to address the three above. > s3: "Preferred-plus and deterministic serialization are subsets of it" so is preferred. Updating text to imply this. > s3: sizes of strings, bstrings, arrays, and maps can also be encoded as various sizes. Maps can be in any order. Tag numbers might be different sizes. Small simples of two bytes are not well-formed, so they don't need to be in the list. It says “CBOR argument” which covers lengths, tag numbers, … I think that is enough. > s4.1: sizes of strings, bstrings, arrays, and maps must be encoded in the smallest number of bytes too. Some rework to be clear that it is CBOR arguments that are the smallest. It assumed that the reader know the CBOR argument is the length of strings, maps, arrays... > s4.2: "Leading zeros MUST be ignored" for bignums. I don't understand this. Shouldn't they error? This goes to my overall point about what this draft means for decoders. This has been clarified. > s5.2: I'd add that protocol designers MAY mandate errors when decoders find inputs that are not in the expected encoding. This now covered in serialization checking > s5.3.2: protocol designers may require maps to be sorted on decode (or produce an error), which is much more efficient to check while decoding. This is worth mentioning in this section. > > s5.3.3: I don't really understand this section, but I think it's because of differences of assumptions. Happy to discuss this more until I know what to ask for? > > s6: "Streaming encoding of strings, arrays, and maps", also bstrs. Fixed > s6: nit: I wish we had an exhaustive list of all of the options, but I don't want to hold this doc up for that work. I think the list pretty complete. We discussed it some on the mailing list and came up with a few more that were added. > s8: I propose a IANA registry for these, but I will pre-agree that it's not worth the effort. Mostly, this is so we're on record as having made an explicit decision. :) I think it’s fine for individual protocols to invent describe their individual special serializations, but this is not a case were we want 1,000 flowers to bloom. There’s not really a good need for this, nor good examples of it than I can see. We only really have three special serializations so far: FIDO’s, dCBOR and the file system OS. Only dCBOR is of general interest. > s9.1: "Another option is to require preferred-plus or deterministic serialization and to have decoders issue a warning" or errors, at the discretion of the protocol designer. Motivated by this comment, the sentence got reworked to be more useful. > c.2: you can add javascript to this list I did. > f: suggest "big integer" instead of "big number" Settled on “bignum” for consistency with 8949. > g: you can add javascript to the list of languages that support big integers I did. > g: another approach that I'm considering enabling with an option in my library is that javascript bigints are always encoded as tag 2/3 and javscript numbers are always encoded as floats (even if expressable as integers), so that they can be round-tripped correctly. > > h: please mention that protocol designers can mandate this if they like. Added. > l: I haven't checked all of the examples. Has someone else? I have checked them and I hope to again, but a cross check would be welcome. LL > > — > Joe Hildebrand > >> On Jul 30, 2026, at 8:19 AM, Barry Leiba <barryleiba@gmail.com> wrote: >> >> With the posting of the -08 version, the Serialization draft is going >> into working group last call. >> >> https://datatracker.ietf.org/doc/draft-ietf-cbor-serialization/ >> >> Please review this version and post issues and comments to the CBOR >> list within the next two weeks: earlier is better. Working group last >> call will end on Friday, 14 August. >> >> Barry, for the chair team >> >> _______________________________________________ >> CBOR mailing list -- cbor@ietf.org >> To unsubscribe send an email to cbor-leave@ietf.org > > _______________________________________________ > CBOR mailing list -- cbor@ietf.org > To unsubscribe send an email to cbor-leave@ietf.org
- [Cbor] Working Group Last Call on Serialization d… Barry Leiba
- [Cbor] Re: Working Group Last Call on Serializati… Anders Rundgren
- [Cbor] Re: Working Group Last Call on Serializati… Laurence Lundblade
- [Cbor] Re: Working Group Last Call on Serializati… Brian Sipos
- [Cbor] Re: Working Group Last Call on Serializati… Rohan Mahy
- [Cbor] Re: Working Group Last Call on Serializati… Brian Sipos
- [Cbor] Re: Working Group Last Call on Serializati… Laurence Lundblade
- [Cbor] What is the data model used in draft-ietf-… Christian Amsüss
- [Cbor] [off-list] What is the data model used in … Christian Amsüss
- [Cbor] Re: Working Group Last Call on Serializati… Vadim Goncharov
- [Cbor] Re: Working Group Last Call on Serializati… Carsten Bormann
- [Cbor] Re: Working Group Last Call on Serializati… Vadim Goncharov
- [Cbor] Re: [Ext] Working Group Last Call on Seria… Paul Hoffman
- [Cbor] Re: [Ext] Working Group Last Call on Seria… Laurence Lundblade
- [Cbor] Re: Working Group Last Call on Serializati… Joe Hildebrand
- [Cbor] Re: Working Group Last Call on Serializati… Laurence Lundblade
- [Cbor] Re: Working Group Last Call on Serializati… Anders Rundgren
- [Cbor] Re: Working Group Last Call on Serializati… Laurence Lundblade
- [Cbor] Re: Working Group Last Call on Serializati… Carsten Bormann
- [Cbor] Re: Working Group Last Call on Serializati… Vadim Goncharov
- [Cbor] Re: Working Group Last Call on Serializati… Laurence Lundblade
- [Cbor] Re: Working Group Last Call on Serializati… Vadim Goncharov
- [Cbor] Re: Working Group Last Call on Serializati… Joe Hildebrand
- [Cbor] Re: Working Group Last Call on Serializati… Joe Hildebrand
- [Cbor] List of all serialization variation (was R… Laurence Lundblade
- [Cbor] Re: List of all serialization variation (w… Joe Hildebrand
- [Cbor] Re: List of all serialization variation (w… Laurence Lundblade
- [Cbor] Re: List of all serialization variation (w… Laurence Lundblade
- [Cbor] Serialization checking and big numbers (wa… Laurence Lundblade
- [Cbor] Re: Serialization checking and big numbers… Laurence Lundblade
- [Cbor] Re: Working Group Last Call on Serializati… Laurence Lundblade
- [Cbor] Re: Working Group Last Call on Serializati… Martine Sophie Lenders
- [Cbor] Promote Appdendix A (was Re: Working Group… Laurence Lundblade
- [Cbor] Re: Working Group Last Call on Serializati… Mikolai Gütschow
- [Cbor] Re: Working Group Last Call on Serializati… Anders Rundgren
- [Cbor] Tag rule -> update to 8949 (was Re: Workin… Laurence Lundblade
- [Cbor] Re: Working Group Last Call on Serializati… Laurence Lundblade
- [Cbor] Re: Working Group Last Call on Serializati… Carsten Bormann
- [Cbor] Re: Working Group Last Call on Serializati… Laurence Lundblade
- [Cbor] Re: Working Group Last Call on Serializati… Laurence Lundblade