pub struct AesGcmSiv { /* private fields */ }
Expand description
AesGcmSiv
is an implementation of the tink_core::Aead
trait.
Implementations§
Trait Implementations§
source§impl Aead for AesGcmSiv
impl Aead for AesGcmSiv
source§fn encrypt(&self, pt: &[u8], aad: &[u8]) -> Result<Vec<u8>, TinkError>
fn encrypt(&self, pt: &[u8], aad: &[u8]) -> Result<Vec<u8>, TinkError>
Encrypt pt
with aad
as additional authenticated data.
The resulting ciphertext consists of two parts: (1) the IV used for encryption and (2) the actual ciphertext (which itself is built of two parts, the inner ciphertext followed by an authentication tag).