This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.
The spec for HKDF's derive bits operation says to throw a TypeError if length is null. I'm wondering if OperationError would be a better choice. For 3 of the 4 other algorithms that support the derive bits operation (ECDH, DH, PBKDF2), they throw an OperationError if the provided length is not valid (which includes if the length is null). The last one (CONCAT) doesn't specify, but it is implied that it would throw an OperationError. Since HKDF is the only one that throws a TypeError if length is null, it seems like it would make more sense to throw an OperationError instead to match the behavior of other algorithms.
Moved to https://github.com/w3c/webcrypto/issues/74