Live Links Kovan Testnet Contract Address: 0xDB6ff940d53698797734E59Fb5f629c7d10229d5 Kovan Deploy TX: 0x088a20921a86ab720ddb1382c345dfb695e8da9084451fa1c53318cd50101c8e Kovan Site (live, interactive): ttps://chainwave-multisignature-wallet.netlify.app/

The Problem:

Your entity or company has a wallet and as a part of governance you require that multiple people need to approve and sign off on transactions before funds can be transferred.

Solution: Chainwave Multi Sig Ethereum Wallet

This wallet allows n number of participants (“approvers” to share control over a wallet’s transactions. We use a super simple quorum which can be set upon contract creation. Basically anyone who is an approver  in the smart contract can submit a transaction. If the transaction is approved by a quorum (usually majority) of all approvers, then the transaction can go through. This multisig wallet demonstrates the simple ability to achieve this.

Features of this multi sig wallet include:

  • Add Approvers
  • Get List of Approvers
  • Create Transfers
  • Get List of Transfers
  • Approve Transfers
  • Modify Quorum (with a vote)
  • Modify Approvers (with a vote)
  • Receive Ether
  • Access Control
  • Web Based Interface

Technologies Utilized

  • Solidity 0.6.0;
  • Infura
  • Truffle Framework
  • React
  • Web3.js

Technical Implementation of Multi Signature Wallet

We cover how we produce this contract in order to demonstrate how Chainwave Engineers build on the blockchain.

Creating a New Transfer in our MultiSig Wallet

First we need to create a data structure to describe transfers. We have created a struct that defines a transfer: Transfer Struct Ethereum With our data structure solved, creating a transfer involves populating a new instance of a “proposed” Transfer and adding it to this contract’s stored array of transfers.
multi signature ethereum wallet
transfer in multi signature ethereum wallet

Approving a Transfer in A Multi Signature Smart Contract

To approve a transfer, we must first check to ensure that the Transfer has not yet been sent and it has not already been approved. If the amount of approvals received by the smart contract reach quorum, then we populate a new ethereum transaction with the information stored in our proposed Transfer. Approving transfer ethereum multisig

Utility Functions: Getting Approvers, Get Transfers, and Access Control

In the smart contract you will also find utility functions to get approvers and other data out of the contract. The most important utility here  is access control. This function restricts actions to users to have been added to the approver array. Access Control Multi Signature Wallet

Testing Multi Sig Wallet Smart Contracts

We use truffle framework to test and deploy smart contracts. Our tests cover the important behaviors that this multi sig wallet achieves, which in include:
  • Creating a Transfer proposal
  • Approval of Transfer with Quorum
  • Ensuring failures when Transfer is incorrectly approved or created
Unit test for Transfer approval Multisig Smart contract Unit test Results of running test suite: Testing multi sig smart contract

Front End Development for Multi Signature Wallet

The front end is built with React for pure front end/UI, while web3.js is used by the front end to interact with the blockchain and wallets.

Live Ethereum Multi Sig Wallet Site

You can see a live demo of the site here. You will need metamask installed in order to interact with the contract

Github Repository

The github respository is located here: https://github.com/ChainWaveLabs/chainwave-multisignature-wallet