pub trait FromBlockCipher {
    type BlockCipher: BlockCipher;
    type NonceSize: ArrayLength<u8>;

    // Required method
    fn from_block_cipher(
        cipher: Self::BlockCipher,
        nonce: &GenericArray<u8, Self::NonceSize>
    ) -> Self;
}
Expand description

Trait for types which can be initialized from a block cipher and nonce.

Required Associated Types§

source

type BlockCipher: BlockCipher

Block cipher

source

type NonceSize: ArrayLength<u8>

Nonce size in bytes

Required Methods§

source

fn from_block_cipher( cipher: Self::BlockCipher, nonce: &GenericArray<u8, Self::NonceSize> ) -> Self

Instantiate a stream cipher from a block cipher

Implementors§