Use the fire coordinator to handle missing or malicious signers #860
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
This PR changes
signer
to use theWSTS
fire::Coordinator
rather than thefrost::Coordinator
. Whereas thefrost::Coordinator
will wait for all signers to send nonces when starting a signing round, thefire::Coordinator
will take the firstthreshold
of responders and attempt to sign with them.If a signer sends a nonce but does not send a signature share before the configured timeout, or sends a signature share that fails to verify, it is excluded from further signing, and another iteration of the current round is attempted. So at every iteration, we either get a good signature, or we reduce the number of available signers. Thus, we are guaranteed to converge to a good signature or a failure.
The
fire::Coordinator
can also runDKG
with less than full participation, but we do not anticipate doing so insBTC
v1
. The timeouts are also configurable, but this PR does not attempt to configure them; rather they are set toNone
as per the existingwsts_state_machine::CoordinatorStateMachine::new
fn
.Closes: #623
Changes
Testing Information
Existing unit and integration tests should demonstrate sufficiently that this code is working. It was necessary to set the signing threshold to
3/7
for some unit test to work around test harness incompatibility with thefire::Coordinator
; this was because the test harness assumed that all signers would send signature shares in every round, which is no longer the case.Checklist: