pub struct BytesSigner { /* private fields */ }Expand description
Simple signer implementation using a cached ed25519 SigningKey.
The SigningKey is created once and reused for all signing operations,
avoiding per-call reconstruction overhead. SigningKey from ed25519-dalek
implements Zeroize on drop, so secret material is securely cleared.
Implementations§
Source§impl BytesSigner
impl BytesSigner
pub fn from_secret(secret: [u8; 32]) -> Self
pub fn from_keypair(keypair: &[u8; 64]) -> Self
Trait Implementations§
Source§impl Clone for BytesSigner
impl Clone for BytesSigner
Source§fn clone(&self) -> BytesSigner
fn clone(&self) -> BytesSigner
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl SignerLike for BytesSigner
impl SignerLike for BytesSigner
fn pubkey_bytes(&self) -> [u8; 32]
fn sign_message(&self, msg: &[u8]) -> [u8; 64]
fn pubkey_base58(&self) -> String
fn sign_message_base58(&self, msg: &[u8]) -> String
Source§impl Zeroize for BytesSigner
impl Zeroize for BytesSigner
impl ZeroizeOnDrop for BytesSigner
Auto Trait Implementations§
impl Freeze for BytesSigner
impl RefUnwindSafe for BytesSigner
impl Send for BytesSigner
impl Sync for BytesSigner
impl Unpin for BytesSigner
impl UnsafeUnpin for BytesSigner
impl UnwindSafe for BytesSigner
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