pub struct Encryptor<N: Network> { /* private fields */ }
Expand description
Tool for encrypting and decrypting Aleo key material into ciphertext
Implementations§
source§impl<N: Network> Encryptor<N>
impl<N: Network> Encryptor<N>
sourcepub fn encrypt_private_key_with_secret(
private_key: &PrivateKey<N>,
secret: &str
) -> Result<Ciphertext<N>>
pub fn encrypt_private_key_with_secret( private_key: &PrivateKey<N>, secret: &str ) -> Result<Ciphertext<N>>
Encrypt a private key into ciphertext using a secret
sourcepub fn decrypt_private_key_with_secret(
ciphertext: &Ciphertext<N>,
secret: &str
) -> Result<PrivateKey<N>>
pub fn decrypt_private_key_with_secret( ciphertext: &Ciphertext<N>, secret: &str ) -> Result<PrivateKey<N>>
Decrypt a private key from ciphertext using a secret
Auto Trait Implementations§
impl<N> RefUnwindSafe for Encryptor<N>where N: RefUnwindSafe,
impl<N> Send for Encryptor<N>
impl<N> Sync for Encryptor<N>
impl<N> Unpin for Encryptor<N>where N: Unpin,
impl<N> UnwindSafe for Encryptor<N>where N: UnwindSafe,
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