-
Notifications
You must be signed in to change notification settings - Fork 15
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Keep polynomial constant parameters during DKG #92
base: main
Are you sure you want to change the base?
Conversation
…x compute::private_poly by exponentiating the arg
…o Polynomial to make code cleaner
…alue from the arg
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Largely, looks good. I gave it a quick look though but will give another one later. Figured I'd add my questions and comments here until then.
I know that we wanted to do this for sBTC and some other potential project. We don't want to go this route for sBTC anymore, but do we still have some other reason for doing this? If not we should probably close this. |
We still want this for other projects. |
The group key created during dkg is the sum of the constant parameters of the party polynomials. This change adds the ability to keep these constant parameters when rerunning dkg, so the group key stays the same. Tests show that it works on both the low level
Signer
interface and the high level state machines.This change also adds
common::Polynomial
, in an attempt to fix the disparity between how we handle private and public polynomials. Private polynomials, which useScalar
for both parameters and args, have been usingpolynomial::Polynomial
from an external crate. But we weren't using any of the advanced features from that crate, just callingeval
to generate private shares. Public polynomials couldn't use the crate, because they havePoint
parameters butScalar
args, which the crate did not support. Also, we couldn't support thekeep_constant
feature with the crate, since it did not allow specifying or editing any of the polynomial parameters.This change is now using
common::Polynomial
for private polynomials, butVec<Point>
for public polynomials (with some help from Polynomial to convert between the two). This is similar to how the code worked before this change, so should require few downstream changes.