decryptSecretBytes method
Decrypts bytes from the given symmetric secret key.
Implementation
Future<List<int>> decryptSecretBytes(
SecretKey secretKey,
List<int> bytes, {
List<int>? aad,
}) async {
final secretBox = SecretBox.fromConcatenation(
bytes,
nonceLength: _nonceLength,
macLength: _macLength,
);
return _cipher.decrypt(
secretBox,
secretKey: secretKey,
aad: aad ?? const [],
);
}