Skip to content

Commit

Permalink
Fix a clippy
Browse files Browse the repository at this point in the history
  • Loading branch information
randombit committed Jun 14, 2024
1 parent 603bbb4 commit fc5ee24
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions pkcs5/src/pbes2/encryption.rs
Original file line number Diff line number Diff line change
Expand Up @@ -49,13 +49,13 @@ fn cbc_decrypt<'a, C: BlockCipherDecrypt + BlockCipher + KeyInit>(
.map_err(|_| Error::EncryptFailed)
}

fn gcm_encrypt<'a, C, NonceSize, TagSize>(
fn gcm_encrypt<C, NonceSize, TagSize>(
es: EncryptionScheme,
key: EncryptionKey,
nonce: Nonce<NonceSize>,
buffer: &'a mut [u8],
buffer: &mut [u8],
pos: usize,
) -> Result<&'a [u8]>
) -> Result<&[u8]>
where
C: BlockCipher + BlockSizeUser<BlockSize = U16> + GcmKeyInit + BlockCipherEncrypt,
aes_gcm::AesGcm<C, NonceSize, TagSize>: GcmKeyInit,
Expand All @@ -75,12 +75,12 @@ where
Ok(&buffer[0..pos + TagSize::USIZE])
}

fn gcm_decrypt<'a, C, NonceSize, TagSize>(
fn gcm_decrypt<C, NonceSize, TagSize>(
es: EncryptionScheme,
key: EncryptionKey,
nonce: Nonce<NonceSize>,
buffer: &'a mut [u8],
) -> Result<&'a [u8]>
buffer: &mut [u8],
) -> Result<&[u8]>
where
C: BlockCipher + BlockSizeUser<BlockSize = U16> + GcmKeyInit + BlockCipherEncrypt,
aes_gcm::AesGcm<C, U12>: GcmKeyInit,
Expand Down

0 comments on commit fc5ee24

Please sign in to comment.