Expand description
This crate defines a set of traits which describe the functionality of block ciphers, block modes, and stream ciphers.
Re-exports§
pub use crypto_common;pub use inout;pub use inout::block_padding;pub use zeroize;pub use crypto_common::generic_array;pub use crypto_common::typenum;
Modules§
Macros§
- impl_
simple_ block_ encdec - Implement simple block backend
Structs§
- Invalid
Length - The error type returned when key and/or IV used in the
KeyInit,KeyIvInit, andInnerIvInitslice-based methods had an invalid length. - Overflow
Error - The error type returned when a cipher position can not be represented by the requested type.
- Stream
Cipher Core Wrapper - Wrapper around
StreamCipherCoreimplementations. - Stream
Cipher Error - This error is returned by the
StreamCiphertrait methods.
Traits§
- Algorithm
Name - Trait which stores algorithm name constant, used in
Debugimplementations. - Array
Length - Trait making
GenericArraywork, marking types to be used as length of an array - Async
Stream Cipher - Marker trait for block-level asynchronous stream ciphers
- Block
Backend - Trait implemented by block cipher encryption and decryption backends.
- Block
Cipher - Marker trait for block ciphers.
- Block
Closure - Trait for
BlockBackendusers. - Block
Decrypt - Decrypt-only functionality for block ciphers.
- Block
Decrypt Mut - Decrypt-only functionality for block ciphers and modes with mutable access to
self. - Block
Encrypt - Encrypt-only functionality for block ciphers.
- Block
Encrypt Mut - Encrypt-only functionality for block ciphers and modes with mutable access to
self. - Block
Size User - Types which process data in blocks.
- Counter
- Counter type usable with
StreamCipherCore. - Inner
IvInit - Types which can be initialized from another type and additional initialization vector/nonce.
- IvSize
User - Types which use initialization vector (nonce) for initialization.
- IvState
- Trait for loading current IV state.
- KeyInit
- Types which can be initialized from key.
- KeyIv
Init - Types which can be initialized from key and initialization vector (nonce).
- KeySize
User - Types which use key for initialization.
- ParBlocks
Size User - Types which can process blocks in parallel.
- SeekNum
- Trait implemented for numeric types which can be used with the
StreamCipherSeektrait. - Stream
Backend - Trait implemented by stream cipher backends.
- Stream
Cipher - Synchronous stream cipher core trait.
- Stream
Cipher Core - Block-level synchronous stream ciphers.
- Stream
Cipher Seek - Trait for seekable stream ciphers.
- Stream
Cipher Seek Core - Block-level seeking trait for stream ciphers.
- Stream
Closure - Trait for
StreamBackendusers. - Unsigned
- The marker trait for compile time unsigned integers.
Type Aliases§
- Block
- Block on which
BlockSizeUserimplementors operate. - Iv
- Initialization vector (nonce) used by
IvSizeUserimplementors. - Key
- Key used by
KeySizeUserimplementors. - ParBlocks
- Parallel blocks on which
ParBlocksSizeUserimplementors operate.