pub type Aes128Gcm = AesGcm<Aes128, U12>;
Available on crate feature
aes
only.Expand description
AES-GCM with a 128-bit key and 96-bit nonce.
Aliased Type§
struct Aes128Gcm { /* private fields */ }
Trait Implementations§
source§impl<Aes, NonceSize, TagSize> AeadCore for AesGcm<Aes, NonceSize, TagSize>where
NonceSize: ArrayLength<u8>,
TagSize: TagSize,
impl<Aes, NonceSize, TagSize> AeadCore for AesGcm<Aes, NonceSize, TagSize>where NonceSize: ArrayLength<u8>, TagSize: TagSize,
§type CiphertextOverhead = UTerm
type CiphertextOverhead = UTerm
The upper bound amount of additional space required to support a
ciphertext vs. a plaintext.
source§impl<Aes, NonceSize, TagSize> AeadInPlace for AesGcm<Aes, NonceSize, TagSize>where
Aes: BlockCipher + BlockSizeUser<BlockSize = U16> + BlockEncrypt,
NonceSize: ArrayLength<u8>,
TagSize: TagSize,
impl<Aes, NonceSize, TagSize> AeadInPlace for AesGcm<Aes, NonceSize, TagSize>where Aes: BlockCipher + BlockSizeUser<BlockSize = U16> + BlockEncrypt, NonceSize: ArrayLength<u8>, TagSize: TagSize,
source§fn encrypt_in_place_detached(
&self,
nonce: &Nonce<NonceSize>,
associated_data: &[u8],
buffer: &mut [u8]
) -> Result<Tag<TagSize>, Error>
fn encrypt_in_place_detached( &self, nonce: &Nonce<NonceSize>, associated_data: &[u8], buffer: &mut [u8] ) -> Result<Tag<TagSize>, Error>
Encrypt the data in-place, returning the authentication tag
source§fn decrypt_in_place_detached(
&self,
nonce: &Nonce<NonceSize>,
associated_data: &[u8],
buffer: &mut [u8],
tag: &Tag<TagSize>
) -> Result<(), Error>
fn decrypt_in_place_detached( &self, nonce: &Nonce<NonceSize>, associated_data: &[u8], buffer: &mut [u8], tag: &Tag<TagSize> ) -> Result<(), Error>
Decrypt the message in-place, returning an error in the event the provided
authentication tag does not match the given ciphertext (i.e. ciphertext
is modified/unauthentic)
source§impl<Aes: Clone, NonceSize: Clone, TagSize> Clone for AesGcm<Aes, NonceSize, TagSize>where
TagSize: TagSize + Clone,
impl<Aes: Clone, NonceSize: Clone, TagSize> Clone for AesGcm<Aes, NonceSize, TagSize>where TagSize: TagSize + Clone,
source§impl<Aes, NonceSize, TagSize> From<Aes> for AesGcm<Aes, NonceSize, TagSize>where
Aes: BlockSizeUser<BlockSize = U16> + BlockEncrypt,
TagSize: TagSize,
impl<Aes, NonceSize, TagSize> From<Aes> for AesGcm<Aes, NonceSize, TagSize>where Aes: BlockSizeUser<BlockSize = U16> + BlockEncrypt, TagSize: TagSize,
source§impl<Aes, NonceSize, TagSize> KeyInit for AesGcm<Aes, NonceSize, TagSize>where
Aes: BlockSizeUser<BlockSize = U16> + BlockEncrypt + KeyInit,
TagSize: TagSize,
impl<Aes, NonceSize, TagSize> KeyInit for AesGcm<Aes, NonceSize, TagSize>where Aes: BlockSizeUser<BlockSize = U16> + BlockEncrypt + KeyInit, TagSize: TagSize,
§fn new_from_slice(key: &[u8]) -> Result<Self, InvalidLength>
fn new_from_slice(key: &[u8]) -> Result<Self, InvalidLength>
Create new value from variable size key.