[][src]Trait signatory::Signer

pub trait Signer<S: Signature>: Send + Sync {
    fn sign(&self, msg: &[u8]) -> Result<S, Error>;
}

Trait for all signers which accept a message (byte slice) and produce a signature of that message using this signer's private key.

Signers should implement this trait for algorithms where there aren't multiple options for the digest function to be used to hash the message, e.g. Ed25519.

Required Methods

Sign the given byte slice with this signer's private key, returning a signature.

Implementors