Giter Site home page Giter Site logo

didhub's Introduction

DIDHub

操作步骤

1.在db/connect.go文件InitDB函数中填写mysql数据库配置信息,如user、password、dbname

2.首先在本地运行ganache,设置rpc server为HTTP://127.0.0.1:7545

3.运行model/did_contract_test.go中的TestDeploy函数,部署智能合约(为区块链上hub存储合约)

4.将部署后的合约地址,填写到model/did_contract.go文件CONTRACT_ADDRESS常量中

5.运行model/vote_contract_test.go中的TestDeployVote函数,部署投票合约(为区块链上流动**投票合约)

6.将部署后的合约地址,填写到model/vote_contract.go文件VOTE_CONTRACT_ADDRESS常量中

准备好智能合约后,即可以被其它模块调用,数据将存储在mysql和智能合约中。

模块功能

本模块为DIDHub模块,为DID Wallet的核心模块,该模块可以实现将DID相关信息存储在mysql中,并上传至区块链。区块链负责存储DID的相关信息,区块链选增以太坊。

didhub's People

Contributors

stupidtao avatar

Watchers

 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.