Update README.md

This commit is contained in:
renchengchang 2019-08-09 17:27:02 +08:00 committed by GitHub
parent 0253108027
commit a2a4950f09
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 18 additions and 11 deletions

View File

@ -1,34 +1,41 @@
# sapling-mpc
This code can be used to participate Multi-party Computation(MPC) phase 2 and verify the result.
This document can be used to participate Multi-party Computation(MPC) phase 2 and verify the result.
## What do I do?
## What should I do?
Contact **jiangyuanshu@tron.network** to schedule a time to participate and get an index num. When it's your turn, you'll receive one mail with `params` file link from us.
1. Send a mail to **jiangyuanshu@tron.network** to apply to participate MPC. You should introduce yourself in email.
1.Download and install IM tool [keybase](https://keybase.io/), if you don't have an account, create it first. You can use it to send file back to us later, our keybase account is `tron_brown`.
2. Tron will send you a email to show your turn and time to participate MPC.
2.If you are running on macOS / Linux / another Unix-like OS, download Rustup and install Rust, run the following in your terminal, then follow the on-screen instructions:
3. When it is your turn, tron will send your a email to notice you and give you a `params` file link which you need to download.
4. Download the `params` file.
5. Download and install IM tool [keybase](https://keybase.io/), if you don't have an account, create it first and add tron' account to your friends. Tron's account is `tron_brown`.
6. Download Rustup and install Rust, run the following in your terminal, then follow the on-screen 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, refer to [rust](https://www.rust-lang.org/learn/get-started) homepage for installation.
3.Get the source code of project sapling-mpc:
7. Get the source code of project sapling-mpc:
```
# git clone https://github.com/tronprotocol/sapling-mpc
```
if git not installed, please refer to [git](https://git-scm.com/downloads) first.
if git has not been installed on your computer, please refer to [git](https://git-scm.com/downloads) first.
4.Download the `params` file by the link in the email sent by tron and put `params` file in the sapling-mpc directory, then run:
8. Put `params` file in the sapling-mpc directory, then run:
```
# cargo run --release --bin compute
```
When it finish, you will get a `new_params` file and hash.
The process could take one to four hours according to your hardware, occupies 1.5 ~ 2GB of memory, and then spits out a `new_params` file. The process also prints a hash. This hash is what you and others can use to verify that your contribution actually ended up in the final parameters.
Notice: this process could take one to four hours according to your hardware, occupies 1.5 ~ 2GB of memory.
9. Send your result to Tron. Send the file `new_params` by keybase and send hash and your system configuration by email and system configuration should coutain os version, cpu model
5.You are encouraged to send file `new_params` to us with keybase, and send us the hash value and your system configuration information with email, such as os version, cpu model. After we receive this `new_params` file, we will check the correctness of transformation and upload it to amazon storage if ok that next participant can use it, then we will also publish hash on [project wiki](https://github.com/tronprotocol/sapling-mpc/wiki).
## Dependency
We reuse the phase 2 result of zcash https://storage.googleapis.com/sapling-mpc/params as the first params of our ceremony. At the end of ceremony, 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.