singleHash function

Uint8List singleHash(
  1. Uint8List buffer
)

This function calculates a single SHA-256 hash of the provided input buffer. It computes a one-time SHA-256 hash without any further processing.

Implementation

Uint8List singleHash(Uint8List buffer) {
  /// Calculate the SHA-256 hash of the input buffer.
  Uint8List tmp = SHA256Digest().process(buffer);

  /// Return the resulting hash.
  return tmp;
}