Type Alias k256::ecdsa::DerSignature
source · pub type DerSignature = Signature<Secp256k1>;
Expand description
ECDSA/secp256k1 signature (ASN.1 DER encoded)
Aliased Type§
struct DerSignature { /* private fields */ }
Implementations
Trait Implementations
source§impl<'de, C> Deserialize<'de> for Signature<C>
impl<'de, C> Deserialize<'de> for Signature<C>
source§fn deserialize<D>(
deserializer: D,
) -> Result<Signature<C>, <D as Deserializer<'de>>::Error>where
D: Deserializer<'de>,
fn deserialize<D>(
deserializer: D,
) -> Result<Signature<C>, <D as Deserializer<'de>>::Error>where
D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl<C> Encode for Signature<C>
impl<C> Encode for Signature<C>
source§fn encoded_len(&self) -> Result<Length, Error>
fn encoded_len(&self) -> Result<Length, Error>
Compute the length of this value in bytes when encoded as ASN.1 DER.
source§fn encode(&self, writer: &mut impl Writer) -> Result<(), Error>
fn encode(&self, writer: &mut impl Writer) -> Result<(), Error>
Encode this value as ASN.1 DER using the provided
Writer
.source§fn encode_to_slice<'a>(&self, buf: &'a mut [u8]) -> Result<&'a [u8], Error>
fn encode_to_slice<'a>(&self, buf: &'a mut [u8]) -> Result<&'a [u8], Error>
Encode this value to the provided byte slice, returning a sub-slice
containing the encoded message.
source§impl<C> PrehashSignature for Signature<C>
impl<C> PrehashSignature for Signature<C>
§type Digest = <C as DigestPrimitive>::Digest
type Digest = <C as DigestPrimitive>::Digest
Preferred
Digest
algorithm to use when computing this signature type.source§impl<C> Serialize for Signature<C>
impl<C> Serialize for Signature<C>
source§fn serialize<S>(
&self,
serializer: S,
) -> Result<<S as Serializer>::Ok, <S as Serializer>::Error>where
S: Serializer,
fn serialize<S>(
&self,
serializer: S,
) -> Result<<S as Serializer>::Ok, <S as Serializer>::Error>where
S: Serializer,
Serialize this value into the given Serde serializer. Read more