pub struct AEAD;Expand description
AEAD is a main entrypoint to encrypt and decrypt the given data (in bytes), and also
generate nonce (in bytes)
Implementations§
Source§impl AEAD
impl AEAD
pub fn nonce() -> Nonce
pub fn encrypt( key: &Key, message: &MessagePlain, ) -> Result<MessageCipher, AeadError>
pub fn decrypt( key: &Key, encrypted: &MessageCipher, ) -> Result<MessagePlain, AeadError>
Auto Trait Implementations§
impl Freeze for AEAD
impl RefUnwindSafe for AEAD
impl Send for AEAD
impl Sync for AEAD
impl Unpin for AEAD
impl UnsafeUnpin for AEAD
impl UnwindSafe for AEAD
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