hash160 function
Computes the RIPEMD160 hash of the given buffer
after applying SHA-256 hash.
This function first applies the SHA-256 hash to the buffer
and then computes
the RIPEMD160 hash of the result.
Returns a Uint8List containing the RIPEMD160 hash.
Implementation
Uint8List hash160(Uint8List buffer) {
/// Apply SHA-256 hash to the buffer
Uint8List tmp = SHA256Digest().process(buffer);
/// Compute the RIPEMD160 hash of the SHA-256 result
return RIPEMD160Digest().process(tmp);
}