Closed cabo closed 8 months ago
Please also set type="cbor-diag" in the CBOR diagnostic notation examples.
{"foo": "bar"}
@cabo I see draft-ietf-cbor-edn-literals-04 uses three dots (...) within a comment, e.g. /.../ In our present draft there was a need to shorten binary strings, short example below:
{
12: h'30593013....D29A54', / SID=2513, proximity-registrar-pubk /
13: "JADA123456789" / SID=2514, serial-number /
}
Would the below be better? This parses as valid CBOR diagnostic notation, while the /.../ shows that something is elided.
{
12: h'30593013/.../D29A54', / SID=2513, proximity-registrar-pubk /
13: "JADA123456789" / SID=2514, serial-number /
}
The elision syntax isn't actually in that draft yet... (a new branch is being set up). But there is an old slide set, https://datatracker.ietf.org/meeting/interim-2022-cbor-03/materials/slides-interim-2022-cbor-03-sessa-elision-00 I'll get back to this issue when I can point out what exactly needs to be done... Just wanted to record it now.
(Doing the elision in a comment also works, but then it looks like these bytes aren't actually there!)
@cabo Thanks, that's enlightening. So it then would become
{
12: h'30593013' ... 'D29A54', / SID=2513, proximity-registrar-pubk /
13: "JADA123456789" / SID=2514, serial-number /
}
The ellipsis notation is now defined in draft-ietf-cbor-edn-literals-06: this is referenced and used. See linked PR: also "cose-diag" code type used for the
Why four dots?