Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

hbswap local devnet #9

Closed
10 tasks done
sbellem opened this issue Dec 23, 2020 · 1 comment
Closed
10 tasks done

hbswap local devnet #9

sbellem opened this issue Dec 23, 2020 · 1 comment

Comments

@sbellem
Copy link

sbellem commented Dec 23, 2020

Issue to track progress for a local devnet, allowing to simulate a deployment and execution of hbswap.

By "local devnet" is meant that components that are assumed to be running on different hosts in a realistic deployment, can be run in a separate containers, and the overall network simulation can be run using a tool such as docker-compose, locally, on one computer.

The current work is under https://github.com/initc3/MP-SPDZ/tree/hbswap-devnet.

The sequence of events/processes that are run is:

# RUN private/local geth node, for development purposes
bash Scripts/hbswap/scripts/chain.sh

# deploy the contracts
go run Scripts/hbswap/go/deploy/deploy.go

# deposit funds
deposit 0 10 10

# preparation phase, in which shares are generated and written to file
# require a multi-party computation
# no interaction with ethereum
bash Scripts/hbswap/scripts/prep.sh

# HTTP servers for input masks
httpserver 0 &
httpserver 1 &
httpserver 2 &
httpserver 3 &

# MPC servers
mpcserver 0 &
mpcserver 1 &
mpcserver 2 &
mpcserver 3 &

# contract/ethereum interactions
secret_deposit 0 10 10
trade 0 1.1 -2.5
trade 0 -1.1 2
secret_withdraw 0 9 9
withdraw 0 9 9

Main components, to run in separate containers

ethereum specific

  • geth node (local/private mode for now)
  • contract deployer - deploys contracts to the chain
  • initialization of funds / deposits

MPC specfic - setup & init phases

  • "trusted setup" - generates keys for MPC nodes
  • compilation of MPC programs, to generate the bytecode -- (although not essential for now, it is nevertheless isolated, because eventually, in future iterations, one can imagine that the bytecode could be generated on a separate machine, and deployed to an MPC network ...)
  • Each MPC node for the preparation phase - initializing/writing shares to file

both ethereum & MPC

  • HTTP servers
  • MPC nodes

client

Notes about the frontend

It has a token list, that contains addresses for the nets (mainnet, testnet, ...)

@sbellem
Copy link
Author

sbellem commented Feb 1, 2021

Closing this as the work is now happening at https://github.com/initc3/HoneyBadgerSwap/pulls.

@sbellem sbellem closed this as completed Feb 1, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant