Cryptographic class
Provides pseudo-cryptographic data.
Constructors
- Cryptographic({int? seed})
-
Provides pseudo-cryptographic data.
const
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- mnemonicPhrase → String
-
Returns BIP-39 looking mnemonic phrase.
no setter
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- seed → int?
-
final
- uuid → String
-
Returns UUIDv4 string.
no setter
Methods
-
apiKey(
{String prefix = '', int length = 32, bool asHex = true}) → String - Returns API key.
-
certificateFingerprint(
{bool asSha256 = true}) → String - Returns certificate fingerprint.
-
hash(
{required Algorithm algorithm}) → String -
Returns random hash.
override
-
jwt(
{Map< String, dynamic> ? payload, String algorithm = 'HS256'}) → String - Returns JWT-like token structure.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
tokenBytes(
{int entropy = 32}) → List< int> -
Returns list of bytes with
entropylength. -
tokenHex(
{int entropy = 32}) → String - Returns a random hex string list.
-
tokenUrlSafe(
{int entropy = 32}) → String - Returns a random URL-safe Base64-encoded string (padded).
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited