CBOR at IETF123

Friday, 25 July 2025, 11:30-13:00 Madrid time

Agenda

Notes

(Minute takers: Marco Tiloca, Christian Amsüss, …)

Chairs' introduction

BL doing introduction

ML: Better to have TR's talk before mine.
BL: We swap the agenda items 2 and 3.

EverCBOR: Formally verified parsers and serializers for CBOR, CDDL and COSE

TR presenting

TR (p2): We implemented a parser/serializer for CBOR (EverCBOR) and a
verifier for CDDL (EverCDDL). Available as open source. A paper got
accepted at ACM CCS 2025.
TR (p3): This is part of a larger project Everest. Projects out of
Everest continue even after conclusion of Everest project.
TR (p4): Workflow of these tools. Produce CDDL from an external source,
then check and generate code (C or Rust).
TR (p5): Support for nondeterministic, and for floating point, is
planned (at least for definite length; indefinite length would cause
issues with constant stack size).
TR: No heap allocations in the library.

RM: On stack usage with arbitrarily … can you restrict the depth?
TR: We could do it. But is it desirable? Between an attacker and a user
sending deeply nested item. Wider discussion.
RM: IMO, if it's a library or command line tool, can decide that based
on a profile.

TR: Serializer will gracefully reject attempts to serialize duplicate
keys. Sometime, partial compile time disjointness checking can be done.

TR (p5): Performance in ballpark of QCBOR and tinycbor. Fast map lookup
by relying on ordering.
TR (p6): Activities at the IETF 123 Hackathon. Confirmed support for
COSE, CWT, EAT, and ace/core drafts using those. -lenders-dns-cbor will
be considered next.
TR: Still missing recursion. Not sure if works in COSE …?, but with RM's
input, may use bound, but from Tuesday, we might not know maximum
nesting.

TR (p7): Found problems with existing docs, eg. missing cuts. CB
suggested filing errata (early August). These patterns might still be
desidered in some cases for extensibility, but are otherwise unlikely
considered.

TR (p8): summarizing. Will follow float discussions around CDE, as those
impact next steps.

CB: Fun doing this at the hackathon; TR found where we swept things
under the rug.
CB: ad p7: 9052 examples where we were more prone to doing that
(difficult document completion). Header map example is not wrong, just
not as selective as it could be. Cuts would give better checking.
CB: 2nd example is special b/c it's a write-only structure (hash only).
Should have erratum anyway.
TR: Erratum for the first definition of header_map too?
CB: No, it's just observation that it's not using CDDL as much as it
could. Serve as trigger to look at other places for having the desired
selectivity.
CB: We knew writing CDDL that cuts are not known to everyone; known to
ppl working with formal languages. Triggered to start campaign.

JOD: Did you look at CDDL extensions?
TR: Not looked at all of them. .cbor, yes. .size, yes. .and and
.within should be easy. For rest, have not looked. Will have to look
at .feature

CB: Nice example of the extensibility discussion that we are having.
CB: Lots of people can use the extension point, also from other groups.
Not necessarily expectation that a tool supporting CDDL supports all of
them, some may be app specific. Of course it'd be nice to have those
from (some) RFCs supported.
CB: I hope we can do the next run of registrations after doing more
formal.

JOD: If CDDL as a tool specifies all this, it's strange to verify those
in a way that can be formally verified.
JOD: Didn't prove CDDL is turing complete -- but the more we have specs
for additional operators (esp. for ~niche cases), the harder it will be
to design tools.
JOD: Suggest that new extensions need to show that they can be
integrated in >=2 tools.

AD: Not many tests in EverCBOR github.
TR: Using old test suite, 29 of them are determinstic. Got links to
further test suites, hope to gather them in single place for more than
just EverCBOR.

CB: Lot of test vectors were generated, maybe we should consolidate them
and put them together following this.
CB: Consolidating test vectors is another campaign to kick off.
HB (chat): We were already talking about improving the test vector
corpus via rfc ir i-d content
CB: Better to have tools than not having them, but then better to have
controls than not have them even without tools, because still better
than prose.

RM: About recursion, you can look to the Mimi content format.
LL: QCBOR has hundreds/thousands of test cases.

Analysis of different -packed configurations when using packed with dns-cbor

ML presenting

ML (p1): focus on the requirements for using Packed CBOR for DNS-CBOR
and related evaluation.
ML (p3): recap on using Packed CBOR with dns-cbor
ML (p4): the use of packed CBOR has been parameterized (A,B,C), with
different proposals for the exact values to use in the final document.
ML (p5): overview of considered data sets used for the evaluation
ML (p6): results
ML (p6): results as a function of the parameter A.
ML (p9): Implementation of dns-cbor updated according to thee use of
(A,B,C), with some parameters irrelevant depending on the setup.
ML (p11-12): Detailed results for different values of A.
ML (p14): Detailed results for different values of A and B.
ML (p16-20): Detailed results for different values of B, having fixed
different value of A.
ML (p21): Conclusions and recommended values for A and B (C was not
evaluated).

CB: On deriving recommendations from the tests: You data is about DNS,
which are not the smallest items we exchange but also not the largest.
Recommendations are for that part of the spectrum. Larger messages tend
to consume more table entries. We know more now, but not covered full
spectrum. Not sure we have to. This is a dominating case for our space.
Just keep this in mind.

Hackathon reports

CB presenting

CB: code sizes; based on MG's implementation.
CB: Would be glad if this could be done with fewer LoC, but 300/400LoC
is not a desaster either.
CB: MG observed: Integration tags have leeway in their meaning. More
flexibility, more work, grown decoder state. Integration tags invented
to address Vadim's comment on not using up the numbers. Still think it's
useful, but keep in mind complexity trade-offs.

Discussion of remaining issues on the three active documents

Packed

CB's introduction slides

CB (p30): exact values to use for the triple (A,B,C). Building on
Martine's and Hackathon results, it seems good to use (12,8,8).
Addresses JH's original comment.
CB: No interop on integration tags yet. If no issues found, hope for
WGLC end of August.
CB (p33): Following-up, there's also 3 editorial and 1 technical issues
left. Also possible to address and close, towards a WGLC end of August.

CB: I'd just put in a counter.

CA (no hat): Serializing 1112 back into CBOR is not a good idea. This is
tool for APIs to avoid fallibility, not for re-serializing it.

MG: Main discussion with VG on the list. I nailed down the main points
in a recent mail on the list. Please have a look and see if you have
comments.
CB: They look right, but I have to read in detail.

BL: Sounds like we're done.

CDE

LL's introduction slides
CB's introduction slides

Floating point NaNs

CB: Most recent discussion was on NaN payload and still targeting a BCP
document.

CB: The former ended up about sticking to RFC 8949 decisions, largely
based on LL input. It's not a nice way, but the best way we can afford.
PR #37 is taking care of this and can be merged. Please read p28 and the
related PR if you care.

Discussions on adding text to CDE that is unrelated

CB: 8949 revisison is not what is planned here. WeAlso, this should not
be the book (Blockchain Commons write one, though). We added content
following the previous WGLC.

Focus of the document

CB (p29): Goals – not normative, just pointers to what is defined.
CB (p29): Non-goals (profiling or menu for profiling).

RM: As doc is written: ambiguous w/rt referencing or defining
serializations. Common Deterministic Encoding – is it a serialization?
Is Preferred Serialization one (presumably)? Other consideratiosn – 5-6y
down the line, we have common and preferred serializations and some
others (like "can't do NaN"), maybe one that doesn't do floats. What
goes where?

Levels, opt-ins and profiles

CB: Profiles go nowhere.
RM: No, others can do that.
CB: This WG shouldn't define profiles. Applications profiling to not do
floats is a good choice for them.
RM: Fine. You never say that these are examples of using CBOR.

RM: Feels like it's a bit word salad; people want to have good
referencable place to say "I'm doing this here".
CB: I'd recommend that people don't point to this RFC, but to its
Section 3.
Bumlefudge (chat only): i can confess to having stumbled on this exact
issue :D
BL: RM, you're saying that the text is not clear.
RM: Even after reading Section 3 four times, I feel it's unclear how we
call these things.
BL: Propose new text to use. I'd like to avoid bloodshed.

CL (chat): As a potential person contributing to this problem, I defined
a profile of CBOR that is "Deterministic Encoding, but maps are allowed
to be in any order." I'm still not certain that was a good idea, but
it's what we did.

LL presenting (single slide)
LL: Mapping of terms against concepts. Highlighting issues from RFC 8949
and mapping of those against concepts of preferred serialization and
expected requirements. Deterministic serialization is simply preferred
serialization with "sort maps" added.
LL: Prefer bullet lists of normative requirements.
RM cheers.
LL:
LL, on CDE document: Started as profile document to deal with dCBOR.
That's why it's off on the wrong foot. All unacknowledged in issue
tracking.

CB: As editor, like actionable comments. Those I can apply. If this is
basis of comments, can't use it, because subtly wrong in many places.
CB: Preferred Serialization is defined in 8949 (even if it has
limitations)
CB: About where things are unclear: read it, they're in. Most specific
was "that's in another section" of 8949.
BL: One comment is that CDE benefits from reorganization.
CB: Talking about 8949.
CB: Editorial round makes sense, as long as target is writing up what is
relevant for CDE, mentioning issues, not rewrite 8949. Minimal
implementation advice pointing to sections or 8949.
CB: Another editorial action to take is being specific about "no new
normative content". It just clarifies. Can we agree 8949 does not need
to be revised? Can we agree that the CDE document can be used to do
deterministic encoding out of experience from RFC 8949?
BL: Is there agreement to keep 8949 the way it is?

RM: Simple to find out: show of hands. I got feedback that those parts
of RFC 8949 are not clear.
Show-of-hands: "Do you think there need to to be normative updates to
8949?"
Outcome: 4 yes, 9 no, 7 no opinion.
RM: Note I don't think CDE needs to change intention. I think it would
be better if the CDE document updates RFC 8949.
BL: What do those 4 think we need to change?

OS (no hat): CB, you disagree with yellow right side of LL slides. But
how about left side?
CB: It simplifies by using new term instead of "preferred serialization"

OS (no hat): Can you produce an updated version of LL's slide that is
correct?
CB: Yes, will do.

CL (on chat) To be clear: I think 8949 is probably normatively correct,
but confusing. But there are ways to reduce confusion that aren't
revising 8949.

LL: My main goal is clarity.
CB (on chat): To summarize: We don't have a technical disagreement. We
do have a disagreement on whether terms defined perfectly well in RFC
8949 should be changed. We also can agree that the clarity of the
document can be improved.

FP: Ad RM's statement about updating. The Update tag is so undefined
that it can mean anything and everything. And the tag can be anything
you want in the first place.
FP: I hear CB saying that what's here would change defined content (and
object), but others' comments are not about changing content but that
it's not clear and needs editorial changes.
OS (on chat): +Francesca
FP (on chat): my question was basically: is this a matter of content or
a matter of clarity of text... because even what Rohan just said right
now (rewrite ...) could be rewrite editorially or could be change the
content of that section. and to be clear, I believe changing the
content to be out of scope of the charter (chairs and AD can comment on
that) but not editorial clarifications

RM: Statement like Definite Length is preferred is meaningless. Either
says "use this" or "use either of". So meaning of "update" would be, if
up to me, rewrite serialziation types that are defined (and apps can
define profiles), replacing that section of the RFC. Understand if ppl
don't want to do that, and will leav it at that.

CL: Struggled with this in downstream spec I wrote, wasn't sure which
encoding I needed for my protocol. I didn't conclude the same things
shown in LL's slide. I don't think that a revision is necessarily
revised, but some clarifications about RFC 8949 made somewhere would
help. CB could do a blog post on that. Something like that would help
the protocol writing community.

OS (on chat): find this picture extremely helpful, and I think some
combination of this diagram (with modifications) and remarks addressing
the yellow text in cde solves this.
CL (on chat): Well, I didn't conclude by reading 8949 that Preferred
Serialization prohibited indefinite-length containers.
CA (on chat): Might be a wording thing. RM complained about it saying
"It is preferred to"...
CB (on chat): That is maybe why defining "Preferred Serialization" and
then leaving one aspect (indefinite length) open wasn't so smart. §4.1
has a conditional requirement, which is not helpful.
CL (on chat): Well, I felt it was perfectly correctly specified. To me,
Preferred Serialization allows indefinite containers and Deterministic
does not.
CB (on chat): "Definite-length encoding is preferred whenever the length
is known at the time the serialization of the item starts."
CB (on chat): The diagram is there
CL (on chat): Yeah, but for a parser, that means I have to assume that I
could get indefinite-length things. Cause I can't know what the encoder
will know and when they will know it.
CB (on chat): Yes, that is exactly what preferred serialization means.
Unfortunate, but clear
CL (on chat): For me, it wasn't "unfortunate", it just meant that I
didn't say "use preferred serialization", I defined my own as a slightly
relaxed version of Deterministic.
CB (on chat): That's why Cde defines "basic serialization".
CL (on chat): I don't have a strong opinion on what any of the profiles
contain, I just want everybody to agree about what they contain.

CB: Precedent: JOSE. Those docs made assumptions on knowledge of
implementers that was too optimistic. Then did a BCP, which was widely
successful. Instead of reading thousands of lines of other RFCs.
CB: Writing it up in concise form is helpful, and I hear the comments
about conciseness.
CB: That should still have background material, not produce text that's
just barely self-sufficient. Thus I think BCP is best way.
CB: Who references 8949 now in other SDO specs won't have reason to
update, new authors can go to BCB.

LL: I'm not set on any particular type of document (like BCP or not). I
just wanted to write the requirements in a sharp way.
LL: Agree that explanatory background is good, but keep it separate.
Hoped that that would go into CDE. So I took the requirements and put
them into my draft.
FP (on chat): (big nodding from Rohan from what Laurence just mentioned
about conciseness and clarity)

LL: CB asks fo actionable comments. I tried, but some of those are about
very large structure of document.
OS (on chat): This is solvable in CDE as a BCP, the suggest from
Laurence, which I agree with is: add a diagram, and use bullet points to
clarify the existing requirements without making changes

BL: Proposal: RM, LL, CB, meet before next interim, work out an
applicability statement that clarifies 8949, and organize in a way that
works for all you.
RM thumbs up, LL kind-a-nods, CB (?)

MG: Got confused by CDE draft. Suggestions; Table 1 is now in. If not
clear enough, could improve there. Now since this is updated, now
clearer (but spent time in it).

BL: Consensus that there are things that are unclear and need to be
reorganized.

CL (on chat): I think Deterministic Serialization also requires you to
leave out tags when they aren't strictly required?
CA (on chat): Generally, tags are not touched by deterministic
serialization (their semantics are generally opaque to the generic data
model) (except for bigums, IIRC)
CB (on chat): We leave most tags to ALDR

Bumblefudge (on chat): For no reason at all, I would love to keep
orthogonal the question of how good the ideas were that went into our
profile from the question of how to document it and inspire libraries to
support it

EDN / -Literals

CB's introduction slides

We did not have the time left to talk about this topic; chairs decided
to use the momentum on on CDE instead.