CBORWriter: Add support for byte string keys.

This CL:
- clarifies that the map keys are sorted according to
  https://tools.ietf.org/html/rfc7049 section 3.9 (with errata 4409), and
- add support for "byte string" keys in map.

We plan to use this to encode signed exchange "Canonical CBOR".

Bug: 803774, 808022
Change-Id: I336a703efe6a3910f069034086b2c84e6a81a075
Reviewed-on: https://chromium-review.googlesource.com/895227
Commit-Queue: Kouhei Ueno <kouhei@chromium.org>
Reviewed-by: Balazs Engedy <engedy@chromium.org>
Cr-Commit-Position: refs/heads/master@{#533714}
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/cbor/+/2015753
Reviewed-by: Yicheng Li <yichengli@chromium.org>
Tested-by: Yicheng Li <yichengli@chromium.org>
3 files changed