Skip to content

feat(sdk-core): add EdDSA MPCv2 offline signing helper utils#8793

Open
vibhavgo wants to merge 1 commit into
masterfrom
WCI-386/eddsa-util-helper
Open

feat(sdk-core): add EdDSA MPCv2 offline signing helper utils#8793
vibhavgo wants to merge 1 commit into
masterfrom
WCI-386/eddsa-util-helper

Conversation

@vibhavgo
Copy link
Copy Markdown
Contributor

Adds shared private utility methods to EddsaMPCv2Utils that will be used across all three createOfflineRound1/2/3Share methods. These are prerequisite helpers that centralize transaction payload extraction, GPG key handling, and authenticated data validation to prevent code duplication.

  • Add domain-separator constant MPS_DSG_SIGNING_USER_GPG_KEY for adata prefixes
  • Add getSignableHexAndDerivationPath() to extract signableHex and derivationPath from txRequest
  • Add getBitgoAndUserGpgKeys() to decrypt user GPG keys with v1 (SJCL) and v2 (Argon2id) envelope support
  • Add validateAdata() to validate authenticated data matches cyphertext adata
  • Import isV2Envelope from baseTypes for envelope version detection
  • Add comprehensive test coverage for all three helper methods in createKeychains.ts

Ticket: WCI-386

@linear-code
Copy link
Copy Markdown

linear-code Bot commented May 18, 2026

WCI-386

@vibhavgo vibhavgo changed the title feat(sdk-core): add EdDSA MPCv2 offline signing helper infrastructure feat(sdk-core): add EdDSA MPCv2 offline signing helper util May 18, 2026
@vibhavgo vibhavgo changed the title feat(sdk-core): add EdDSA MPCv2 offline signing helper util feat(sdk-core): add EdDSA MPCv2 offline signing helper utils May 18, 2026
Ticket: WCI-386

Adds shared private utility methods to EddsaMPCv2Utils that will be used
across all three createOfflineRound1/2/3Share methods. These are prerequisite
helpers that centralize transaction payload extraction, GPG key handling, and
authenticated data validation to prevent code duplication.

- Add MPS_DSG_SIGNING_USER_GPG_KEY domain-separator constant for adata prefixes
- Add getSignableHexAndDerivationPath() to extract signableHex and
  derivationPath from txRequest
- Add getBitgoAndUserGpgKeys() to decrypt user GPG keys with v1 (SJCL)
  and v2 (Argon2id) envelope support
- Add validateAdata() to validate authenticated data matches cyphertext adata
- Import isV2Envelope from baseTypes for envelope version detection
- Add comprehensive test coverage for all three helper methods
@vibhavgo vibhavgo force-pushed the WCI-386/eddsa-util-helper branch from 73179bb to f4ebbae Compare May 18, 2026 10:40
@vibhavgo vibhavgo marked this pull request as ready for review May 18, 2026 11:04
@vibhavgo vibhavgo requested review from a team as code owners May 18, 2026 11:04
@vibhavgo vibhavgo requested review from Marzooqa and bdesoky May 18, 2026 11:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant