DartAesGcm class
AesGcm cipher implemented in pure Dart.
- Inheritance
-
- Object
- Cipher
- StreamingCipher
- AesGcm
- DartAesGcm
- Implemented types
Constructors
- DartAesGcm({int secretKeyLength = 32, int nonceLength = 12})
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- macAlgorithm → MacAlgorithm
-
Message authentication code (MacAlgorithm) used by the cipher.
no setterinherited
- nonceLength → int
-
Number of bytes in the nonce ("Initialization Vector", "IV", "salt").
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- secretKeyLength → int
-
Number of bytes in the SecretKey.
final
Methods
-
decrypt(
SecretBox secretBox, {required SecretKey secretKey, List< int> aad = const <int>[], int keyStreamIndex = 0}) → Future<List< int> > -
Decrypts a ciphertext.
override
-
decryptSync(
SecretBox secretBox, {required SecretKeyData secretKeyData, List< int> aad = const <int>[], int keyStreamIndex = 0}) → List<int> -
encrypt(
List< int> clearText, {required SecretKey secretKey, List<int> ? nonce, List<int> aad = const <int>[], int keyStreamIndex = 0}) → Future<SecretBox> -
Encrypts a cleartext.
override
-
encryptSync(
List< int> clearText, {required SecretKeyData secretKeyData, List<int> ? nonce, List<int> aad = const <int>[], int keyStreamIndex = 0}) → SecretBox -
newNonce(
) → List< int> -
Generates a new nonce with the correct length (nonceLength).
inherited
-
newSecretKey(
) → Future< SecretKey> -
Generates a new SecretKey with the correct length (secretKeyLength).
inherited
-
newSecretKeyFromBytes(
List< int> bytes) → Future<SecretKey> -
Constructs a new SecretKey from the bytes.
inherited
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited