Crate subhasher

Source
Expand description

Minimal implementation of Substrate hash.

Functionsยง

blake2_128
Hash the data into a 16-bytes array with BLAKE2 algorithm.
blake2_256
Hash the data into a 32-bytes array with BLAKE2 algorithm.
blake2_512
Hash the data into a 64-bytes array with BLAKE2 algorithm.
blake2_128_concat
Hash the data into blake2_128(data) + data.
identity
Return data directly.
keccak256
Hash the data into a 32-bytes array with Keccak algorithm.
keccak512
Hash the data into a 64-bytes array with Keccak algorithm.
sha2_256
Hash the data into a 32-bytes array with SHA2 algorithm.
twox64
Hash the data into a 8-bytes array with XX algorithm.
twox64_concat
Hash the data into twox_64(data) + data.
twox128
Hash the data into a 16-bytes array with XX algorithm.
twox256
Hash the data into a 32-bytes array with XX algorithm.