Type Alias sp_core::ecdsa::Signature

source ·
pub type Signature = SignatureBytes<SIGNATURE_SERIALIZED_SIZE, EcdsaTag>;
Expand description

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

Aliased Type§

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

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.

source

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

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

Trait Implementations§

source§

impl CryptoType for Signature

§

type Pair = Pair

The pair key type of this crypto.
source§

impl From<RecoverableSignature> for Signature

source§

fn from(recsig: RecoverableSignature) -> Signature

Converts to this type from the input type.