encryptToBase64 static method
Criptografa text e retorna o payload como string base64.
final b64 = CryptUtil.encryptToBase64('segredo', key: key);
final txt = CryptUtil.decryptFromBase64(b64);
Implementation
static String encryptToBase64(
String text, {
Uint8List? key,
Uint8List? nonce,
List<int>? aad,
}) =>
encryptText(text, key: key, nonce: nonce, aad: aad).toBase64();