Skip to main content

Keygen

This distributed key generation forms the basis for all subsequent MPC operations, providing a secure foundation for the wallet with enhanced privacy and security guarantees.

Step 1 : Create Session


Step 2 : Perform Keygen


  • Call duoSession.keygen() which returns Result of Success with Keyshare ByteArray or Failure with exception.

Example


Example.kt
suspend fun performKeygen(duoSession: DuoSession): ByteArray {
return withContext(Dispatchers.IO) {
duoSession.keygen().getOrThrow()
}
}