XChaCha20withPrefix class

With XChaCha20, regardless of whether with or without prefix, a block is created first with the HChaCha20 and the first and last four elements are taken from this as the new key. For the key creation the first 32 bytes are taken. The nonce is taken for the block consists of 8 zeros, followed by the remaining 16 bytes of the nonce. The encrypted text is then generated using ChaCha20 and the new key and nonce.

Constructors

XChaCha20withPrefix()

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

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

Static Methods

decrypt({required String key, required String nonce, required String ciphertext}) Future<String>
encrypt({required String key, required String nonce, required String plaintext}) Future<String>