Skip to main content

signWithUserShare(hashedMessages_b64: string[], signatureScheme: string): Promise<SignWithUserShareResponse>

This method allows the AeonSigner to use its locally managed key share (the user’s secret cryptographic material) to participate in Ika’s distributed signature generation for one or more pre-hashed messages.

Parameters

  • hashedMessages_b64: string[] - An array of Base64 encoded strings, where each string is a pre-hashed message digest to be signed as part of the MPC protocol. The hashing algorithm used to produce these digests is defined by the signatureScheme.
  • signatureScheme: string - An identifier for the specific MPC signature scheme (e.g., “ECDSA”,“EDDSA”). This informs the SDK how to process the local key share and interact with the MPC protocol.

Returns

  • Promise<SignWithUserShareResponse>: A promise that resolves with the user’s signature contribution and a message.
    • SignWithUserShareResponse:
      • signature_b64: string - The Base64 encoded string of the resulting cryptographic signature component (e.g., a partial signature in a threshold scheme, or the complete signature if this AeonSigner is the final party or the scheme is non-threshold for this user). This output is typically then sent to the MPC coordination service (“ika”) or other participants.
      • message: string - A descriptive message about the outcome of the signing operation (e.g., “Partial signature generated successfully”, “MPC round N completed”).

Example