webauthn
webauthn copied to clipboard
Fix type of AuthenticatorAttestationResponseJSON.publicKeyAlgorithm
Fixes https://github.com/w3c/webauthn/issues/2065.
AuthenticatorAttestationResponseJSON was added in the L3 drafts, so we can easily change
AuthenticatorAttestationResponseJSON.publicKeyAlgorithm to type long (or COSEAlgorithmIdentifier) since L3 isn't formally released yet. AuthenticatorAttestationResponseJSON.publicKeyAlgorithm is also in output (covariant) position, so changing its type to be more restrictive is even backwards compatible.
I misspoke on the 2024-05-15 call: I said the range of CBOR integers is any value whose size in bits can be represented by uint64_t. This was incorrect - uint64_t (2^64-1) is the max value range, not a value size range.