# Module crypto::sha3 [−] [src]

An implementation of the SHA-3 cryptographic hash algorithms.

There are 6 standard algorithms specified in the SHA-3 standard:

- `SHA3-224`
- `SHA3-256`
- `SHA3-384`
- `SHA3-512`
- `SHAKE128`, an extendable output function (XOF)
- `SHAKE256`, an extendable output function (XOF)
- `Keccak224`, `Keccak256`, `Keccak384`, `Keccak512` (NIST submission without padding changes)

Based on an implementation by Sébastien Martini

# Usage

An example of using `SHA3-256` is:

    use self::crypto::digest::Digest;
    use self::crypto::sha3::Sha3;

    // create a SHA3-256 object
    let mut hasher = Sha3::sha3_256();

    // write input message
    hasher.input_str("abc");

    // read hash digest
    let hex = hasher.result_str();

    assert_eq!(hex, "3a985da74fe225b2045c172d6bd390bd855f086e3e9d525b46bfe24511431532");

## Structs

Sha3 |

## Enums

Sha3Mode | SHA-3 Modes.

# Help

## Keyboard Shortcuts

?
  Show this help dialog
S
  Focus the search field
⇤
  Move up in search results
⇥
  Move down in search results
⏎
  Go to active search result
+
  Collapse/expand all sections

## Search Tricks

Prefix searches with a type followed by a colon (e.g. `fn:`) to restrict the search to a given type.

Accepted types are: `fn`, `mod`, `struct`, `enum`, `trait`, `type`, `macro`, and `const`.

Search functions by type signature (e.g. `vec -> usize` or `* -> vec`)