Crate digest[][src]

This crate provides traits for describing funcionality of cryptographic hash functions.

By default std functionality in this crate disabled. (e.g. method for hashing Readers) To enable it turn on std feature in your Cargo.toml for this crate.

Re-exports

pub extern crate generic_array;

Macros

impl_opaque_debug

Macro for defining opaque Debug implementation. It will use the following format: "HasherName { ... }". While it's convinient to have it (e.g. for including in other structs), it could be undesirable to leak internall state, which can happen for example through uncareful logging.

Structs

InvalidBufferLength

The error type for variable hasher result

InvalidLength

The error type for variable digest output

InvalidOutputSize

The error type for variable hasher initialization

Traits

BlockInput

Trait to indicate that digest function processes data in blocks of size BlockSize. Main usage of this trait is for implementing HMAC generically.

Digest

The Digest trait specifies an interface common for digest functions.

ExtendableOutput

Trait which describes extendable output (XOF) of hash functions. Using this trait you first need to get structure which implements XofReader, using which you can read extendable output.

FixedOutput

Trait for returning digest result with the fixed size

Input

Trait for processing input data

VariableOutput

Trait for returning digest result with the varaible size

XofReader

Trait for decribing readers which are used to extract extendable output from the resulting state of hash function.