Go to file
jiangyuanshu 8cad498a23 update README.md 2019-12-31 11:40:41 +08:00
src/bin Add the output of the randomness beacon, courtesy of Jason Davies. 2018-08-04 13:12:19 -06:00
.gitignore Initial commit 2018-04-08 17:30:38 -06:00
COPYRIGHT Initial commit 2018-04-08 17:30:38 -06:00
Cargo.lock Add implementation of random beacon for phase 2 of Sapling MPC. 2018-08-02 01:23:30 -06:00
Cargo.toml Add implementation of random beacon for phase 2 of Sapling MPC. 2018-08-02 01:23:30 -06:00
LICENSE-APACHE Initial commit 2018-04-08 17:30:38 -06:00
LICENSE-MIT Initial commit 2018-04-08 17:30:38 -06:00
README.md update README.md 2019-12-31 11:40:41 +08:00

README.md

mpc

This document is a guide to participating in Multi-party Computation(MPC) phase 2 and verifying the result.

What should I do ?

  1. Send an email to tronz_mpc@tronz.io to apply to participate in MPC. Please introduce yourself in the email and tell us your available time.

  2. TRON will send you an email about the time for you to participate in MPC.

  3. When it is your turn, TRON will send you a notification email and give you a params file link which you will need to download.

  4. Download the params file on server. Minimum requirements of server requires:

    • Processor (CPU): Intel Core i5 (sixth generation or newer) or equivalent
    • Operating System: Linux (Recommended) / macOS / Windows 7+
    • Memory: 8 GB RAM
    • Storage: 500 GB internal storage drive
  5. Download and install IM tool keybase. If you don't have an account yet, create an account and add TRON' account as your friends. TRON's account is tronz_mpc.

  6. Run the following code in your terminal to download Rustup and install Rust, then follow the instructions if you are running on macOS / Linux / another Unix-like OS:

# curl https://sh.rustup.rs -sSf | sh

If you are running on windows, please go to rust homepage for installation instruction. In linux, you may need to run as prompted after installation:

# source $HOME/.cargo/env
  1. Obtain the source code of project mpc:
# git clone https://github.com/tronprotocol/mpc

If git has not been installed on your computer, please refer to git first.

  1. Put params file in the mpc directory, then run:
# cargo run --release --bin compute

When its finished, you will get a new_params file and a hash which you will need to memorize. You can find the hash and new_params as shown below:

Notice: this process could take 0.5 ~ 1 hours according to your hardware capacity and occupy 1.5 ~ 2GB of memory.

  1. Send your result to TRON. Send the file new_params by keybase and hash by email. Feel free to state your os version in email. E.g. windows 7/centos 7.

Dependency

We reuse the phase 2 result of zcash https://download.z.cash/sapling-mpc/params as the first params of the process. At the end of process, we generate the random beacon by using one Bitcoin block's hash as the seed of pseudo random number generator; The block's height will not be determined until last participant completes his operation. After we verify all participants' contribution, we will publish all hash on project wiki page. Anyone can do this verification as belows.

How to verify my contribution ?

After all participants finish the process, we will announce final params at aws. Following as below to verify your contribution:

# cd mpc
# wget https://mpcfilepub.s3.amazonaws.com/mpc/params
# wget https://mpcfilepub.s3.amazonaws.com/powersoftau/powersoftau_phase1_files.tar
# tar xvf powersoftau_phase1_files.tar && cp powersoftau_phase1_files/* .
# cargo run --release --features="verification" --bin verify

This verification may take about 1 hour and then output all participants' contribution. Find whether your hash is in the list.

License

Licensed under either of

at your option.

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.