SymmetricCipher class abstract
Base class for symmetric cipher implementations. Extends Cipher, mixes in ISymmetric for keyId implementation, and implements ISymmetricCipher.
- Inheritance
-
- Object
- ExpirationBase
- Cipher
- SymmetricCipher
- Implemented types
- Mixed-in types
- Implementers
- Annotations
-
- @includeInBarrelFile
Constructors
- SymmetricCipher(InputSymmetricCipher input)
- Constructs a SymmetricCipher with the given input parameters.
Properties
- algorithm → CryptoAlgorithm
-
The cryptographic algorithm associated with this object.
no setterinherited
- expirationDate → DateTime?
-
The expiration date, or null if not set.
no setterinherited
- expirationTimes → int?
-
Maximum number of allowed usages before expiration.
no setterinherited
- expirationTimesRemaining → int?
-
Remaining number of allowed usages.
no setterinherited
- hashCode → int
-
The hash code for this object.
no setterinherited
- key → String
-
The symmetric key as a string.
no setteroverride
- keyId → Digest
-
Returns the SHA-256 hash of the key material as a hex string.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
decrypt(
List< int> data) → List<int> -
Decrypts the given data.
inherited
-
encrypt(
List< int> data) → List<int> -
Defines encryption and decryption operations for ciphers.
Encrypts the given data.
inherited
-
incrementUse(
) → void -
Increments the usage counter for expiration times.
inherited
-
isExpired(
) → bool -
Returns true if the object is expired.
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