-
Notifications
You must be signed in to change notification settings - Fork 329
Closed
Labels
bugunintended behaviour in ecdsa codeunintended behaviour in ecdsa code
Milestone
Description
When the DER signature is malformed, the VerifyingKey.verify(sigdecode=sigdecode_der)
raises unexpected exceptions and in some cases does not raise any exception.
UnexpectedDER
, IndexError
and AssertionError
are raised in addition to BadSignatureError
, at the same time flipping the 4th or 6th least significant bit of 2nd byte of a NIST521p signature does not cause it to be rejected (the DER encoding is strict, and every value has one defined encoding, any other encoding is invalid and needs to be rejected)
Metadata
Metadata
Assignees
Labels
bugunintended behaviour in ecdsa codeunintended behaviour in ecdsa code