NativeFrostApi class
FrostApi backed by a native (FFI/platform) implementation.
Every call maps onto the matching BuFrostApi endpoint via
unwrapOrThrowCryptoError, exactly like NativeMuSig2Api maps onto
BuMusig2Api. The k1* methods drive the secp256k1 suite (33-byte
points), the ed* methods the Ed25519 suite (32-byte points). Key
shares cross as [id:u32 LE][share:32] records and commitments as
[id:u32 LE][hiding][binding] records, mirroring BuFrostShare and
BuFrostCommitment.
- Implemented types
Constructors
- NativeFrostApi(BuFrostApi api)
-
const
Properties
- api → BuFrostApi
-
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
edAggregate(
{required List< FrostCommitment> commitments, required List<int> message, required List<int> groupPublicKey, }) → FrostThresholdSignature -
Aggregate signature shares →
(R, z)(Ed25519 suite).override -
edCombine(
bool isScalar = true}) → BuBytes -
Combine share records → 32-byte secret (Ed25519 suite).
override
-
edCommit(
{List< int> ? hidingRandomness, List<int> ? bindingRandomness, bool isScalar = true}) → FrostNoncePair -
Round-1 commit (Ed25519 suite).
override
-
edGroupFromMembers(
{required List< int> ids, required List<int> pubsConcat, required int threshold}) → BuBytes -
Group key from member points (Ed25519 suite):
ids+pubsConcat(nx 32 B).threshold: 0 = additive sum, else Lagrange at zero.override -
edGroupInfo(
{required List< int> vssConcat, required int nComms, required int max}) → FrostGroupInfo -
Group key +
maxmember keys from a VSS commitment (Ed25519 suite).override -
Signing-share preparation (Ed25519 suite): expand seeds when
isScalaris false, then additive-rescale like k1PrepareShares.override -
Threshold reshare (additive, Ed25519 suite):
ids+seedsConcat(n32-byte RFC 8032 seeds, expanded in the backend) +coeffSeedsConcat(n * (threshold - 1)32-byte seeds) → fresh shares, member pubs and group key. Requiresn >= 2,2 <= threshold <= n.override -
edShard(
{required List< int> secret, required List<int> coefficients, required int maxParticipants, bool isScalar = true}) → FrostDealerShard -
Dealer shard (Ed25519 suite): same shapes, 32-byte points.
isScalar: true (default) = canonical scalars, false = RFC 8032 seeds expanded in the backend.override -
edSign(
{required int identifier, required List< int> groupPublicKey, required FrostNoncePair nonces, required List<FrostCommitment> commitments, required List<int> message, bool isScalar = true}) → BuBytes -
Round-2 signature share (Ed25519 suite).
override
-
edVerify(
{required List< int> commitment, required List<int> z, required List<int> groupPublicKey, required List<int> message}) → bool -
Verify a final
(R, z)signature (Ed25519 suite).override -
Verify one participant's signature share (Ed25519 suite).
override
-
edVssCommit(
{required List< int> coeffsConcat, required int nCoeffs}) → BuBytes -
Feldman VSS commitment (Ed25519 suite):
nCoeffsscalars →nCoeffs32-byte points.override -
k1Aggregate(
{required List< FrostCommitment> commitments, required List<int> message, required List<int> groupPublicKey, }) → FrostThresholdSignature -
Aggregate signature shares →
(R, z).override -
k1Combine(
) → BuBytes -
Combine share records → 32-byte secret (Lagrange at zero).
override
-
k1Commit(
{List< int> ? hidingRandomness, List<int> ? bindingRandomness}) → FrostNoncePair -
Round-1 commit: 32-byte
secretShare+ caller 32-bytehidingRandomness/bindingRandomness(or fresh randomness when null) → nonce scalars + commitments.override -
k1GroupFromMembers(
{required List< int> ids, required List<int> pubsConcat, required int threshold}) → BuBytes -
Group key from member points:
ids+pubsConcat(nx 33 B).threshold: 0 = additive sum, else Lagrange interpolation at zero. Pure public-key math inside the backend.override -
k1GroupInfo(
{required List< int> vssConcat, required int nComms, required int max}) → FrostGroupInfo -
Group key +
maxmember keys from a VSS commitment (nCommsconcatenated 33-byte points, secret commitment first).override -
Signing-share preparation: expand + additive-rescale
shares([id:u32 LE][share:32]records) →n32-byte scalars, same order.threshold: 0 = additive full-set rescale, else Shamir passthrough. All secret math happens inside the backend; shape errors throw.override -
Threshold reshare (additive):
ids(nparticipant identifiers) +secretsConcat(n32-byte scalars) +coeffsConcat(n * (threshold - 1)32-byte scalars, row-major) → fresh shares, member pubs and group key. Requiresn >= 2,2 <= threshold <= n.override -
k1Shard(
{required List< int> secret, required List<int> coefficients, required int maxParticipants}) → FrostDealerShard -
Dealer shard: 32-byte
secret+ concatenated 32-byte polynomialcoefficients(secret excluded) → one share record per participant (1..=[maxParticipants]).override -
k1Sign(
{required int identifier, required List< int> groupPublicKey, required FrostNoncePair nonces, required List<FrostCommitment> commitments, required List<int> message}) → BuBytes -
Round-2 signature share (32 bytes) for
identifier.override -
k1Verify(
{required List< int> commitment, required List<int> z, required List<int> groupPublicKey, required List<int> message}) → bool -
Verify a final
(R, z)signature (Appendix B Schnorr).override -
Verify one participant's signature share.
override
-
k1VssCommit(
{required List< int> coeffsConcat, required int nCoeffs}) → BuBytes -
Feldman VSS commitment:
nCoeffsscalars →nCoeffs33-byte points.override -
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