AESGCMCipher

Trait AESGCMCipher 

Source
pub trait AESGCMCipher {
    type Ctx;
    type KeySize: ArrayLength<u8>;

    // Required methods
    fn new(key: GenericArray<u8, Self::KeySize>) -> Self;
    fn encrypt(&mut self, plain: &[u8]) -> Result<Vec<u8>, Error>;
    fn decrypt(&mut self, ciph: &[u8]) -> Result<Vec<u8>, Error>;
}

Required Associated Types§

Required Methods§

Source

fn new(key: GenericArray<u8, Self::KeySize>) -> Self

Source

fn encrypt(&mut self, plain: &[u8]) -> Result<Vec<u8>, Error>

Source

fn decrypt(&mut self, ciph: &[u8]) -> Result<Vec<u8>, Error>

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§