Expand description
DER encoding and decoding of ECDSA signatures.
TLS and X.509 carry ECDSA signatures as the ASN.1 ECDSA-Sig-Value
structure:
ECDSA-Sig-Value ::= SEQUENCE {
r INTEGER,
s INTEGER
}The curve implementations in this crate operate on the fixed-width
r || s form instead ([u8; 64] for P-256, [u8; 96] for P-384). These
helpers convert between the two.
Enums§
- Ecdsa
Error - Errors returned while converting ECDSA signatures to or from DER.
Functions§
- decode_
p256_ signature_ der - Decodes an
ECDSA-Sig-ValueDER structure into a fixed-width P-256r || ssignature. - decode_
p384_ signature_ der - Decodes an
ECDSA-Sig-ValueDER structure into a fixed-width P-384r || ssignature. - decode_
signature_ der - Decodes an
ECDSA-Sig-ValueDER structure intoraw_out. - encode_
signature_ der - Encodes the ECDSA values
rands(each big-endian, optionally with leading zero bytes) as anECDSA-Sig-ValueDER structure.