[][src]Module estahr::hash

This module provides functions to calculate the hash of strings and files. The hashes can be in absolute value or in hex. (hex is usually preferred)

The hashing (file & string) provided include:

  1. MD5 (for compatibility, not recommended due to proven weaknesses).
  2. SHA2 - 256
  3. SHA2 - 512
  4. SHA3 - 256
  5. SHA3 - 512
  6. BLAKE 2s (256 bit)
  7. BLAKE 2b (512 bit)
  8. BLAKE 3 (256 bit)

Enums

HashAlgorithm

This represents the type of hash algorithm.

Functions

hash_file

Hashes the given file with the selected hash algorithm.

hash_string

Hashes the given string with the selected hash algorithm.