frost_enrollment: specify reduced enrollment v2

This commit is contained in:
Kgothatso Ngako committed 2026-11-18 22:20:50 +02:00
1 parent 7a35fde10f
commit 4690e742ab
2 files changed
+112 -8

No files matched your search

+4 -3
View File
@@ -11,9 +11,10 @@ extern "C" {
#include <stddef.h>
#include <stdint.h>
/** This module implements FROST enrollment, the protocol of Section 4.1.1 of
* the FROST paper (https://eprint.iacr.org/2017/1155.pdf). It converts a
* (t, n) FROST group into a (t, n+1) group without re-running key generation
/** This module implements FROST enrollment, the full enrollment RTS of
* Section 4.1.1 of "A Survey and Refinement of Repairable Threshold Schemes"
* (https://eprint.iacr.org/2017/1155.pdf). It converts a (t, n) FROST group
* into a (t, n+1) group without re-running key generation
* and without any participant revealing its secret share. The same mechanism
* repairs a lost share: running it with the target identifier of an existing
* participant reproduces exactly that participant's share.
@@ -1,11 +1,12 @@
Notes on the frost_enrollment module API
========================================
This module implements FROST enrollment, the protocol of Section 4.1.1 of the
FROST paper (https://eprint.iacr.org/2017/1155.pdf). It turns a (t, n) FROST
group into a (t, n+1) group without re-running key generation and without any
participant revealing its secret share, and it repairs a lost share by running
the same protocol at the identifier of an existing participant.
This module implements FROST enrollment, the full enrollment RTS of Section
4.1.1 of "A Survey and Refinement of Repairable Threshold Schemes"
(https://eprint.iacr.org/2017/1155.pdf). It turns a (t, n) FROST group into a
(t, n+1) group without re-running key generation and without any participant
revealing its secret share, and it repairs a lost share by running the same
protocol at the identifier of an existing participant.
Unlike the frost module, which tracks BIP 445, this protocol has no BIP. It is
specified by the paper and by the reference proof of concept at
@@ -27,6 +28,108 @@ serialization and the share-splitting derivation — are frozen by the
regression vectors, so changing one is a deliberate, vector-breaking change
rather than a silent one.
Reduced enrollment version 2 specification
==========================================
This is the normative specification for the reduced-enrollment revision being
implemented. Until the versioned API lands, the sections below describe the
existing version 1 full-enrollment implementation. The target protocol is the
reduced enrollment RTS from Section 4.1.3 of Laing and Stinson's survey, linked
from https://gist.github.com/nickfarrow/64c2e65191cde6a1a47bbd4572bf8cf8.
Scope and security model
------------------------
Version 2 has two operations. Enrollment turns a `(t, n)` group into a `(t,
n+1)` group at `new_id = n`; repair recreates the existing share at `new_id <
n`. Both retain the original group public key, threshold, polynomial and
existing shares. Neither operation refreshes the polynomial or revokes a copied
share. Signer removal, threshold changes, proactive refresh and fragment-based
enrollment are outside this protocol.
Participants are identified by `uint32` identifiers `0..n-1`, and identifier
`i` corresponds to polynomial x-coordinate `i+1`. The helper set contains `u`
unique existing participant identifiers, sorted numerically for protocol
purposes, with `2 <= t <= u`. The target cannot be a helper. Enrollment allows
`u <= n`; repair allows at most `n-1` helpers. The paper specifies `u = t`.
Support for `u > t` uses the same triangular-matrix construction and requires
the generalized coalition argument to be reviewed before the experimental
warning can be removed.
The privacy goal is the enrollment RTS goal against coalitions of fewer than t
participants executing the protocol honestly. Every helper-to-helper and
helper-to-target secret value MUST use a confidential and authenticated channel.
Public-share verification detects a bad result but does not identify a helper
that supplied a bad sigma; identifiable malicious fault tolerance is not
claimed. Authorization is separate from authentication and remains a caller
precondition: a helper must run only after approving the exact session, group,
helper set, operation and target.
Triangular share exchange
-------------------------
Write `h_0, ..., h_(u-1)` for the sorted helpers, `x_new = new_id+1`, and `q`
for the secp256k1 group order. Helper `h_i` computes
lambda_i = product_{k != i} (new_id-h_k)/(h_i-h_k) mod q
v_i = lambda_i * secshare_i.
For every `j > i`, it generates a random masking scalar `delta_(j,i)`. Entries
`delta_(j,i)` with `j < i` are structurally zero and are not transmitted. The
helper keeps the diagonal remainder
delta_(i,i) = v_i - sum_{j=i+1}^{u-1} delta_(j,i) mod q
and sends `delta_(j,i)` to helper `h_j` only when `j > i`. Helper `h_j` then
computes and sends to the target
sigma_j = sum_{i=0}^{j} delta_(j,i) mod q.
The target sums all u sigma values. The result is `f(x_new)` because every row
sums to `v_i`, every column sums to `sigma_j`, and the sum of the weighted
shares is the Lagrange interpolation of `f` at `x_new`.
The triangular exchange sends `u(u-1)/2` helper-to-helper values and u
helper-to-target values, for `u(u+1)/2` values in total. For `u = t`, this is
the communication complexity proven optimal for the reduced enrollment RTS.
Buffers may retain a square `u*32` representation for API alignment, but zero
cells are not routing markers: canonical sender and recipient identifiers
determine which cells have messages.
Session and message contract
----------------------------
A target starts a run with a fresh 32-byte session identifier. A version 2
parameters hash binds the reduced-protocol domain, threshold public key, n, t,
new_id, sorted helper identifiers and session identifier. The share-splitting
hash has a separate reduced-protocol domain and binds the same parameters hash
as well as the sender and recipient identifiers. These version 2 tags and
encodings deliberately replace the frozen version 1 encodings; there is no
implicit wire compatibility between the full and reduced protocols.
Every transmitted delta or sigma is accompanied by its parameters hash and
sender identifier; a delta also names its recipient. A recipient accepts only
the exact expected sender/recipient pairs and one contribution per sender. The
target checks every helper's parameters hash, not merely a representative one.
The checked target API requires an expected public share and returns a secret
share only after `secshare*G` equals it.
The expected public share may be interpolated from authenticated public shares
or evaluated from an authenticated aggregate VSS commitment polynomial. Neither
construction authenticates its own inputs. In particular, matching the constant
commitment or interpolated group key does not stop colluding helpers from
supplying a different polynomial with the same constant term. The target MUST
authenticate the group descriptor independently of the enrollment messages.
After enrollment, all existing participants and the target must update n and
append the derived public share only after verification. Repair leaves group
metadata unchanged. The library supplies deterministic derivation and
verification; transport, authorization, consensus and atomic persistent state
updates remain application responsibilities.
Version 1 full-enrollment protocol
==================================
The protocol
------------