Skip to content

Preflight check

Alexander Kolotov edited this page May 9, 2018 · 14 revisions

Deployment

  1. Prepare Multisig contracts for Home and Foreign
  2. Choose number of validators (3 for example). Gather ETH public keys.
  3. Fund with POA and ETH all 3 keys. Try small amounts first. (max 1 eth, 1 poa)
  4. Choose required signatures threshold (2 for example)
  5. Fund temporary deployment account from which all contracts will be deployed.
  6. git clone poa-bridges contracts; npm install; npm run compile
  7. cd deploy && npm install
  8. prepare .env file with correct RPC URLs, Validators eth addresses, Max, Min, Daily thresholds
  9. run node deploy.js
  10. Update https://medium.com/poa-network/introducing-poa-bridge-and-poa20-55d8b78058ac medium post with official contract address
  11. deploy all validator's nodes using Mr. X scripts
  12. deploy bridge UI
  13. deploy monitoring

Checks

  1. run test tx from home to foreign
  2. run test tx from foreign to home
  3. increase home daily limit
  4. increase foreign daily limit
  5. add validator on home and foreign
  6. stop the bridge operations by changing the limits, make sure that the bridge does not relay transactions
  7. accidentally send POA20 to foreign address and use claimTokens to withdraw from it
  8. stop all bridges and make sure monitoring works
  9. change contract addresses and make sure monitoring works
  10. roll back local dbs on validators and make sure they don't do double spend
  11. make malicious validator's tx and make sure monitoring works on home
  12. make malicious validator's tx on foreign and make sure monitoring works
  13. spend all money on validator account and check monitoring
  14. try to deposit more than max deposit value
  15. try to deposit less than min deposit value
  16. try to withdraw more than max withdraw value
  17. try to withdraw less than min withdraw value
  18. hit daily limit
  19. verify it waits for 8 blocks before sending tx
  20. upgrade bridge contracts to new version and make sure that balances of POA and POA20 was not changed, the bridge can still withdraw and deposit (withdraw first), rollback of dbs will not lead to double spend
Clone this wiki locally