Module hash

Module hash 

Source
Expand description

Hashing utilities using SHA-2, SHA-3, BLAKE2, and BLAKE3 families.

This module provides convenient wrappers around:

  • SHA-256 and SHA-512 (always available)
  • SHA3-256 and SHA3-512 (with extended-hashes feature)
  • BLAKE2b-512 and BLAKE2s-256 (with extended-hashes feature)
  • BLAKE3 (with extended-hashes feature)

Functions§

sha256
Computes SHA-256 hash of the input data.
sha512
Computes SHA-512 hash of the input data.
sha256_hex
Computes SHA-256 hash with hex-encoded output.
sha512_hex
Computes SHA-512 hash with hex-encoded output.

Type Aliases§

Sha256Digest
SHA-256 digest output (32 bytes).
Sha512Digest
SHA-512 digest output (64 bytes).