feat(sdk-lib-mpc): EddsaRetrofitData type + DKG retrofit constructor + getFirstMessage routing - #9481
Open
bitgo-ai-agent-dev[bot] wants to merge 1 commit into
Open
Conversation
Contributor
ralph-bitgo
Bot
force-pushed
the
WCI-1261-EddsaRetrofitData-DKG-constructor
branch
from
August 12, 2026 07:05
e79929c to
990112e
Compare
bitgo-ai-agent-dev
Bot
force-pushed
the
WCI-1261-EddsaRetrofitData-DKG-constructor
branch
from
August 12, 2026 07:22
990112e to
54a371c
Compare
ralph-bitgo
Bot
force-pushed
the
WCI-1261-EddsaRetrofitData-DKG-constructor
branch
from
August 12, 2026 07:22
54a371c to
045559a
Compare
bitgo-ai-agent-dev
Bot
force-pushed
the
WCI-1261-EddsaRetrofitData-DKG-constructor
branch
from
August 12, 2026 08:30
045559a to
e94d057
Compare
ralph-bitgo
Bot
force-pushed
the
WCI-1261-EddsaRetrofitData-DKG-constructor
branch
from
August 12, 2026 08:31
e94d057 to
cf3cb10
Compare
bitgo-ai-agent-dev
Bot
force-pushed
the
WCI-1261-EddsaRetrofitData-DKG-constructor
branch
from
August 12, 2026 10:53
cf3cb10 to
b5193dd
Compare
ralph-bitgo
Bot
force-pushed
the
WCI-1261-EddsaRetrofitData-DKG-constructor
branch
from
August 12, 2026 10:53
b5193dd to
fdf95f7
Compare
Base automatically changed from
WCI-1263-getMpcV2RetrofitDataFromMpcV1Key-EdDSA
to
master
August 13, 2026 06:24
bitgo-ai-agent-dev
Bot
force-pushed
the
WCI-1261-EddsaRetrofitData-DKG-constructor
branch
from
August 13, 2026 06:27
fdf95f7 to
d219ede
Compare
ralph-bitgo
Bot
force-pushed
the
WCI-1261-EddsaRetrofitData-DKG-constructor
branch
2 times, most recently
from
August 13, 2026 06:49
8f72917 to
58ebac8
Compare
bitgo-ai-agent-dev
Bot
force-pushed
the
WCI-1261-EddsaRetrofitData-DKG-constructor
branch
from
August 13, 2026 07:24
58ebac8 to
8d67c7c
Compare
ralph-bitgo
Bot
force-pushed
the
WCI-1261-EddsaRetrofitData-DKG-constructor
branch
2 times, most recently
from
August 13, 2026 08:39
9ad91ef to
20b67fd
Compare
bitgo-ai-agent-dev
Bot
force-pushed
the
WCI-1261-EddsaRetrofitData-DKG-constructor
branch
from
August 13, 2026 10:16
20b67fd to
9ade6eb
Compare
ralph-bitgo
Bot
force-pushed
the
WCI-1261-EddsaRetrofitData-DKG-constructor
branch
from
August 13, 2026 10:16
9ade6eb to
61fb76a
Compare
bitgo-ai-agent-dev
Bot
force-pushed
the
WCI-1261-EddsaRetrofitData-DKG-constructor
branch
from
August 13, 2026 12:21
61fb76a to
20a5005
Compare
…+ getFirstMessage routing Add optional retrofitData parameter to the DKG constructor so parties can seed a retrofit DKG ceremony from their existing MPCv1 scalar instead of generating fresh key material. - Import and store EddsaRetrofitData on the DKG class instance. - Constructor gains a 4th optional param: retrofitData?: EddsaRetrofitData. - getFirstMessage branches on this.retrofitData: when set it calls wasm.ed25519_dkg_round0_import passing the party's clamped scalar, aggregate public key, and chain code; otherwise falls through to the existing ed25519_dkg_round0_process path. - Export EddsaRetrofitData as a named type from eddsa-mps/index.ts. - Bump @bitgo/wasm-mps 1.11.0 -> 1.12.0 which exports ed25519_dkg_round0_import with a proper TypeScript signature. - getSession/restoreSession now round-trip retrofitData so a persisted session correctly resumes the retrofit path. - retrofitData is cleared after getFirstMessage consumes it to bound the lifetime of the private scalar. - generateEdDsaDKGKeyShares in util.ts accepts per-party retrofitData params forwarded to the DKG constructor. - Add retrofit DKG tests: routing, determinism, session persistence, and full end-to-end restore round-trip. Ticket: WCI-1261
bitgo-ai-agent-dev
Bot
force-pushed
the
WCI-1261-EddsaRetrofitData-DKG-constructor
branch
from
August 13, 2026 14:30
20a5005 to
6117b6d
Compare
Marzooqa
marked this pull request as ready for review
August 13, 2026 15:59
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
What
constructor in `modules/sdk-lib-mpc/src/tss/eddsa-mps/dkg.ts`.
`wasm.ed25519_dkg_round0_import` with the party's clamped scalar,
aggregate public key, and chain code; otherwise fall through to the
existing `ed25519_dkg_round0_process` path.
callers can import it directly without going through the `MPSTypes` namespace.
`ed25519_dkg_round0_import` with a proper TypeScript signature — no
`as any` cast needed) and update `yarn.lock` accordingly.
`retrofitData` params and forward them to the `DKG` constructor.
Why
hold a valid EdDSA scalar (`pShare.u`). Generating fresh key material would
produce a new public key, breaking wallet continuity.
retrofit DKG ceremony that produces MPCv2 shares for the same aggregate
public key, enabling transparent migration without user action.
produce identical `dkgStateBytes` format, so no downstream code changes.
Test plan
Ticket: WCI-1261