Crate digest

Source
Expand description

This crate provides traits which describe functionality of cryptographic hash functions and Message Authentication algorithms.

Traits in this repository are organized into the following levels:

Additionally hash functions implement traits from the standard library: Default, Clone, Write. The latter is feature-gated behind std feature, which is usually enabled by default by hash implementation crates.

Modules§

block_buffer
Fixed size buffer for block processing of data.
const_oid
RustCrypto: Object Identifiers (OIDs)
core_api
Low-level traits operating on blocks and wrappers around them.
crypto_common
Common cryptographic traits.

Macros§

impl_oid_carrier
Implement dummy type with hidden docs which is used to “carry” hasher OID for CtVariableCoreWrapper.

Structs§

CtOutput
Fixed size output value which provides a safe Eq implementation that runs in constant time.
InvalidBufferSize
Buffer length is not equal to hash output size.
InvalidLength
The error type returned when key and/or IV used in the KeyInit, KeyIvInit, and InnerIvInit slice-based methods had an invalid length.
InvalidOutputSize
The error type used in variable hash traits.
MacError
Error type for when the Output of a Mac is not equal to the expected value.

Traits§

Digest
Convenience wrapper trait covering functionality of cryptographic hash functions with fixed output size.
DynDigest
Modification of the Digest trait suitable for trait objects.
ExtendableOutput
Trait for hash functions with extendable-output (XOF).
ExtendableOutputReset
Trait for hash functions with extendable-output (XOF) able to reset themselves.
FixedOutput
Trait for hash functions with fixed-size output.
FixedOutputReset
Trait for hash functions with fixed-size output able to reset themselves.
HashMarker
Marker trait for cryptographic hash functions.
InnerInit
Types which can be initialized from another type (usually block ciphers).
KeyInit
Types which can be initialized from key.
Mac
Convenience wrapper trait covering functionality of Message Authentication algorithms.
MacMarker
Marker trait for Message Authentication algorithms.
OutputSizeUser
Types which return data with the given size.
Reset
Resettable types.
Update
Types which consume data with byte granularity.
VariableOutput
Trait for hash functions with variable-size output.
VariableOutputReset
Trait for hash functions with variable-size output able to reset themselves.
XofReader
Trait for reader types which are used to extract extendable output from a XOF (extendable-output function) result.

Type Aliases§

Key
Key used by KeySizeUser implementors.
Output
Output array of OutputSizeUser implementors.