This is needed to use the COSE_Key format for WebAuthN public keys.
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/06ae32d640c8e4b86ea8914a80ee419ea16e56d8 commit 06ae32d640c8e4b86ea8914a80ee419ea16e56d8 Author: Jun Choi <hongjunchoi@chromium.org> Date: Thu Dec 21 21:33:39 2017 Support CBOR encoding and decoding of negative integers Added support for major type 1 for CBORValue, CBORReader, and CBORWriter, and reduced the accepted range of major type 0 to what fits in an int64_t. While the CBOR major types 0 and 1 together can represent integers in the range [-2^64, 2^64-1], to reduce the C++ interface complexity we now represent them both in an int64_t, with the range [-2^63, 2^63-1]. Bug: 786217 Change-Id: Ifee69efcddecea104532b99176d705b3d2801f41 Reviewed-on: https://chromium-review.googlesource.com/777807 Commit-Queue: Jun Choi <hongjunchoi@chromium.org> Reviewed-by: Balazs Engedy <engedy@chromium.org> Reviewed-by: Jeffrey Yasskin <jyasskin@chromium.org> Cr-Commit-Position: refs/heads/master@{#525809} [modify] https://crrev.com/06ae32d640c8e4b86ea8914a80ee419ea16e56d8/content/browser/webauth/cbor/cbor_reader.cc [modify] https://crrev.com/06ae32d640c8e4b86ea8914a80ee419ea16e56d8/content/browser/webauth/cbor/cbor_reader.h [modify] https://crrev.com/06ae32d640c8e4b86ea8914a80ee419ea16e56d8/content/browser/webauth/cbor/cbor_reader_unittest.cc [modify] https://crrev.com/06ae32d640c8e4b86ea8914a80ee419ea16e56d8/content/browser/webauth/cbor/cbor_values.cc [modify] https://crrev.com/06ae32d640c8e4b86ea8914a80ee419ea16e56d8/content/browser/webauth/cbor/cbor_values.h [modify] https://crrev.com/06ae32d640c8e4b86ea8914a80ee419ea16e56d8/content/browser/webauth/cbor/cbor_values_unittest.cc [modify] https://crrev.com/06ae32d640c8e4b86ea8914a80ee419ea16e56d8/content/browser/webauth/cbor/cbor_writer.cc [modify] https://crrev.com/06ae32d640c8e4b86ea8914a80ee419ea16e56d8/content/browser/webauth/cbor/cbor_writer.h [modify] https://crrev.com/06ae32d640c8e4b86ea8914a80ee419ea16e56d8/content/browser/webauth/cbor/cbor_writer_unittest.cc
Comment 1 by kpaulhamus@chromium.org
, Nov 17 2017