pub struct SignatureService { /* private fields */ }
Implementations§
Source§impl SignatureService
impl SignatureService
pub fn new() -> Self
pub fn sign(&self, message: Vec<u8>, private_key: SecretKey) -> Signature
pub fn sign_with_rng<R: Rng + CryptoRng>( &self, message: Vec<u8>, private_key: SecretKey, rng: &mut R, ) -> Signature
pub fn verify( &self, message: Vec<u8>, signature: Signature, public_key: XOnlyPublicKey, ) -> Result<(), Error>
Trait Implementations§
Auto Trait Implementations§
impl Freeze for SignatureService
impl RefUnwindSafe for SignatureService
impl Send for SignatureService
impl Sync for SignatureService
impl Unpin for SignatureService
impl UnwindSafe for SignatureService
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