shake128 function

Uint8List shake128(
  1. Uint8List input,
  2. int outlen
)

Helper function for easy use of SHAKE128. Absorbs input and extracts outlen bytes from the XOF.

Implementation

Uint8List shake128(Uint8List input, int outlen) {
  final SHAKE128 shake = SHAKE128();
  shake.absorb(input);
  shake.finalizeAbsorption();
  return shake.squeeze(outlen);
}