Falcon class
The Falcon signature scheme for a given degree n (a power of two,
2..1024).
final falcon = Falcon(512);
final (sk, vk) = falcon.keygen();
final sig = falcon.sign(sk, message);
assert(falcon.verify(vk, message, sig));
- Available extensions
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- n → int
-
no setter
- param → FalconParams
-
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
hashToPoint(
Uint8List message, Uint8List salt) → List< int> -
Hash
message(bound tosalt) to a point in Z_qx/(x^n+1). -
keygen(
{List< List< ? polys, RandomBytes? randombytes}) → (SecretKey, Uint8List)int> > -
Available on Falcon, provided by the FalconKeygen extension
Generate a key pair(secretKey, verificationKey). -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
sign(
SecretKey sk, Uint8List message, {RandomBytes? randombytes}) → Uint8List -
Available on Falcon, provided by the FalconSign extension
Signmessagewithsk. Ifrandombytesis provided it is used both as the salt source and to seed the per-attempt ChaCha20 sampler, making the signature reproducible (and byte-identical to the reference). When null, a secure source is used directly. -
toString(
) → String -
A string representation of this object.
inherited
-
verify(
Uint8List vk, Uint8List message, Uint8List signature) → bool -
Available on Falcon, provided by the FalconVerify extension
Verifysignatureovermessageagainst the verification keyvk.
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited