GithubHelp home page GithubHelp logo

multi-sig-factory's Introduction

MultiSig Wallet Factory

RSK Mainnet: 0xbda3deb48Ee37965B7D88EAc0a0E204bC2427c06

RSK Testnet: 0x677bCBb40d511857d706f4D2E9825c96380c72F5

Source: gnosis/MultiSigWallet

Create a Multi Sig

  1. Get the project
git clone https://github.com/rsksmart/multi-sig
cd multi-sig
npm i
  1. Create .secret file with 12 words mnemonic.

  2. Run the project

npx truffle console --network [mainnet/testnet/regtest]
  1. Create a wallet
  • Instantiate factory regarding network address

    truffle(mainnet)> let factory = await MultiSigWalletFactory.at('0xbda3deb48ee37965b7d88eac0a0e204bc2427c06')
    
    truffle(testnet)> let factory = await MultiSigWalletFactory.at('0x677bcbb40d511857d706f4d2e9825c96380c72f5')
    
  • Create the wallet

    truffle(mainnet)> let owners = ['0xf4...0d', '0x5g...aa', ...]
    truffle(mainnet)> let required = 2
    truffle(mainnet)> factory.create(owners, required)
    # wait for tx confirmation
    
  • Validate

    truffle(mainnet)> factory.getInstantiationCount(accounts[0]).then(c => factory.instantiations(accounts[0], c.sub(web3.utils.toBN(1))))
    '0x86...d4'
    truffle(mainnet)> let multi = await MultiSigWallet.at('0x86...d4')
    undefined
    truffle(mainnet)> multi.getOwners()
    [
      '0xf4...0d',
      '0x5g...aa',
      ...
    ]
    truffle(mainnet)> multi.required().then(r => r.toString())
    '2'
    

multi-sig-factory's People

Contributors

ilanolkies avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.