decrypt method

Future<String> decrypt({
  1. required String encryptedData,
  2. required String password,
})

Decrypts the provided AES-encrypted data.

  • encryptedData: The AES-encrypted data to be decrypted.
  • password: The password or key used for decryption.

Returns a Future containing the decrypted plaintext as a String.

Implementation

Future<String> decrypt(
    {required String encryptedData, required String password}) {
  return BouncyCastleSecurityPlatform.instance
      .decrypt(encryptedData, password);
}