Signature

Type Alias Signature 

Source
pub type Signature = GenericSignature<Public>;
Expand description

A signature (a 512-bit value, plus 8 bits for recovery ID).

Uses blake2 during key recovery.

Aliased Type§

#[repr(transparent)]
pub struct Signature(pub [u8; 65], _);

Tuple Fields§

§0: [u8; 65]

Implementations§

Source§

impl Signature

Source

pub fn recover<M: AsRef<[u8]>>(&self, message: M) -> Option<Public>

Recover the public key from this signature and a message.

Trait Implementations§

Source§

impl CryptoType for Signature

Source§

type Pair = GenericPair<CryptoBytes<PUBLIC_KEY_SERIALIZED_SIZE, (PublicTag, EcdsaTag)>>

The pair key type of this crypto.
Source§

impl Recover for Signature

Source§

type Public = CryptoBytes<PUBLIC_KEY_SERIALIZED_SIZE, (PublicTag, EcdsaTag)>

The public key that will be recovered from the signature.
Source§

fn recover_prehashed(&self, message: &[u8; 32]) -> Option<Self::Public>

Recover the public key from this signature and a pre-hashed message.
Source§

fn recover<M: AsRef<[u8]>>(&self, message: M) -> Option<Self::Public>

Recover the public key from this signature and a message.