enarx / ciborium

CBOR utilities
Other
254 stars 58 forks source link

[Feature]: Support for decoding unassigned simple values #60

Open anweiss opened 2 years ago

anweiss commented 2 years ago

Is there an existing issue for this?

Description

When decoding CBOR data that contains unassigned simple values, as in those that aren't of false, true, null or undefined, an error is thrown:

https://github.com/enarx/ciborium/blob/9a4511065f87e853cd37e085ac3bcc387ba495d0/ciborium/src/de/mod.rs#L191

A minimal repro was posted by @Anrock at https://github.com/anweiss/cddl/issues/90#issuecomment-982470668.

It would be great to be able to capture these values so that CDDL tools can validate these values.

Acceptance Criteria

No response

Suggestions for a technical implementation

No response

Anrock commented 1 year ago

@dpal is there any plans to implement this? anweiss/cddl is almost the only cddl-tool in a good shape and having such breakers in it is a pity