Trait sp_beefy::BeefyVerify

source ·
pub trait BeefyVerify<MsgHash: Hash> {
    type Signer: BeefyAuthorityId;

    // Required method
    fn verify(&self, msg: &[u8], signer: &Self::Signer) -> bool;
}
Expand description

Means of verification for a BEEFY authority signature.

Accepts custom hashing fn for the message and custom convertor fn for the signer.

Required Associated Types§

source

type Signer: BeefyAuthorityId

Type of the signer.

Required Methods§

source

fn verify(&self, msg: &[u8], signer: &Self::Signer) -> bool

Verify a signature.

Return true if signature is valid for the value.

Implementors§

source§

impl<MsgHash: Hash> BeefyVerify<MsgHash> for AuthoritySignaturewhere <MsgHash as Hash>::Output: Into<[u8; 32]>,