Skip to main content

hash_algorithm

Function hash_algorithm 

Source
pub const fn hash_algorithm() -> &'static str
Expand description

Returns the name of the active hash algorithm

The algorithm is selected at compile time based on feature flags:

  • fastGxHash (requires AES-NI), falls back to AHash
  • secureAHash (DoS-resistant)
  • crypto — Blake3 (cryptographic)
  • default — DefaultHasher (std) or FNV-1a (no_std)

§Examples

let algo = domain_key::hash_algorithm();
println!("Using hash algorithm: {algo}");