Closed selfissued closed 8 years ago
I need to find the correct reference, but I believe that if y is zero then you have a bad point.
I believe that this is true for some curves, but even if so, the "y >= 0" would be correct both for curves that allow 0 and those that don't.
Fixed in pull cose-wg/cose-spec#105
Changed to use the SEC1 algorithm instead of trying to make it easy.
This looks good now. Thanks.
Section 13.1.1 (Double Coordinate Curves) of draft -08 contains this text: When encoding the sign of y, the expression 'y > 0' is evaluated and encoded a CBOR boolean.
Given that the sign bit of a zero value is 0, I suspect that should actually be "y >= 0" so that it evaluates to true for all values with a zero sign bit.