sign method
Signs payload, returning at most
ASTBinaryFormat.maxSignatureLength bytes.
payload covers the header, every section and the CRC-32 — so an attacker
cannot edit the content, recompute the CRC, and leave a signature that
still verifies.
Implementation
@override
Uint8List sign(Uint8List payload) =>
Uint8List.fromList(_hmac.convert(payload).bytes);