I wrote nested varints. Gmail overrode me.

The problem is that you can't DER encode an object in a single forward pass
because you can't write the outermost object until its length is known and
you don't know that till you have the lengths of the inner objects and so
on.

BER is much easier because you can use the indefinite length encoding.

DER would have been much easier if it had chosen the indefinite length
encoding of lists and prohibited the definite length.



On Thu, Oct 9, 2025 at 2:46 PM Laurence Lundblade <[email protected]>
wrote:

>
>
> On Oct 9, 2025, at 10:59 AM, Phillip Hallam-Baker <[email protected]>
> wrote:
>
> If you are going to replace DER with CBOR, fine. DER is probably the
> single biggest reason for hatred of ASN.1. The problem being you have to
> encode nested variants.
>
>
> What are the nested variants you speak of?
>
> Not BER, DER, CER, PER… because we just said it is DER and DER doesn’t
> have variants.
>
> LL
>
>
_______________________________________________
COSE mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to