pub struct Ecb<C> { /* private fields */ }Expand description
Electronic Codebook (ECB) mode.
This is included because SP 800-38A defines it, but it should only be used for single-block operations or controlled test vectors. It leaks repeated plaintext patterns.
Implementations§
Source§impl<C: BlockCipher> Ecb<C>
impl<C: BlockCipher> Ecb<C>
Sourcepub fn encrypt_nopad(&self, data: &mut [u8])
pub fn encrypt_nopad(&self, data: &mut [u8])
Encrypt block-aligned data in place without padding.
Sourcepub fn decrypt_nopad(&self, data: &mut [u8])
pub fn decrypt_nopad(&self, data: &mut [u8])
Decrypt block-aligned data in place without padding.
Auto Trait Implementations§
impl<C> Freeze for Ecb<C>where
C: Freeze,
impl<C> RefUnwindSafe for Ecb<C>where
C: RefUnwindSafe,
impl<C> Send for Ecb<C>where
C: Send,
impl<C> Sync for Ecb<C>where
C: Sync,
impl<C> Unpin for Ecb<C>where
C: Unpin,
impl<C> UnsafeUnpin for Ecb<C>where
C: UnsafeUnpin,
impl<C> UnwindSafe for Ecb<C>where
C: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more