newSecretKey method

  1. @override
Future<SecretKey> newSecretKey()
override

Generates a new SecretKey.

It will have the correct length (secretKeyLength).

The source of random bytes is Random.secure (a cryptographically secure random number generator) unless a custom random number generator was specified when you constructed the cipher (or your Cryptography instance).

Implementation

@override
Future<SecretKey> newSecretKey() {
  return fallback.newSecretKey();
}