About

This is a fork of yushan created by Nick Farrow for BTC++ Taipei FROST Workshop. It is highly recommended to first take a look at that demo which is POC of multiple independent parties signing a message using FROST.

This fork is instead intended to be a POC for a single party employing FROST to distribute key shares over multiple servers for signing. Rather than having multiple independent parties manually participating in the FROST key generation and signing rounds this POC has multiple server nodes automatically communicating with a coordinator to participate in the FROST rounds.

The inspriation for this POC was to mitigate the risk inherent to storing hot keys on a single server by distributing the key shares accross multiple servers that can collaboratively sign, while even having some key shares offline in cold storage. Validating Lightning Server attempts to mitigate this risk by moving the signing keys to a second validating server in the case of lightning hot wallets, however it doesn't eliminate the risk factor of having a single server storing the signing key.

How To Run

  1. Spin up the number of yushan-nodes desired (same as the number of key shares)
  2. Configure each yushan-node to have the desired ROOM ID, PARTICIPANTS (number of key shares), THRESHOLD (number of key shares required for signing), and assign a unique INDEX for each (from 1 to the number of key shares) and hit SUBSCRIBE
  3. Spin up a single yushan-coordinator and configure it with the same ROOM ID, PARTICIPANTS (number of key shares), THRESHOLD (number of key shares required for signing) and hit SUBSCRIBE
  4. Observe as the yushan-coordinator and yushan-nodes automatically particpate in key generation
  5. Turn off the yushan-nodes that do not need to be available during message signing (only a THRESHOLD number of yushan-nodes should remain online)
  6. On the yushan-coordinator enter a message to be signed
  7. Observe as the yushan-coordinator and yushan-nodes automatically participate in the message signing
  8. Manually verify the signed message at the bottom of the yushan-coordinator page

A yushan-node can be served from within the node directory, a yushan-coordinator can be served from within the coordinator directory. Simple way to serve these is using python http module python -m http.server <port>.

Caveats

This fork uses a local nostr relay being served at http://localhost:7777 to communicate. This will be required for this POC to work (or change the nostr relays that are used in the index.html files).

Built With

Share this project:

Updates