Trait engine::vault::Encrypt [−][src]
pub trait Encrypt<T: From<Vec<u8>>>: AsRef<[u8]> { fn encrypt<B: BoxProvider, AD: AsRef<[u8]>>(
&self,
key: &Key<B>,
ad: AD
) -> Result<T> { ... } }
trait for encryptable data. Allows the data to be encrypted.
Provided methods
fn encrypt<B: BoxProvider, AD: AsRef<[u8]>>(
&self,
key: &Key<B>,
ad: AD
) -> Result<T>
[src]
&self,
key: &Key<B>,
ad: AD
) -> Result<T>
encrypts a raw data and creates a type T from the ciphertext