pub struct Signer(/* private fields */);Expand description
An object used to sign messages. For security reasons cannot be serialized.
Implementations§
Source§impl Signer
impl Signer
Sourcepub fn sign_with_rng(
&self,
rng: &mut (impl CryptoRng + RngCore),
message: &[u8],
) -> Signature
pub fn sign_with_rng( &self, rng: &mut (impl CryptoRng + RngCore), message: &[u8], ) -> Signature
Signs the given message using the given RNG.
Sourcepub fn sign(&self, message: &[u8]) -> Signature
Available on crate feature default-rng only.
pub fn sign(&self, message: &[u8]) -> Signature
default-rng only.Signs the given message using the default RNG.
Sourcepub fn verifying_key(&self) -> PublicKey
pub fn verifying_key(&self) -> PublicKey
Returns the public key that can be used to verify the signatures produced by this signer.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Signer
impl RefUnwindSafe for Signer
impl Send for Signer
impl Sync for Signer
impl Unpin for Signer
impl UnwindSafe for Signer
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more