Coder Social home page Coder Social logo

salimihabib / iroha-dotnet Goto Github PK

View Code? Open in Web Editor NEW

This project forked from hyperledger-archives/iroha-dotnet

0.0 1.0 0.0 290 KB

.NET library for Hyperledger Iroha, a simple distributed ledger.

Home Page: https://wiki.hyperledger.org/display/iroha

License: Apache License 2.0

C++ 69.10% C# 30.90%

iroha-dotnet's Introduction

Iroha .NET

What is Iroha?

Iroha is this.

Description

Iroha .NET is client library for using iroha for .NET.

Requirements

  • Visual Studio 2015
  • .NET Framework 4.5+
  • Windows 7+

Building

Build an entire solution

  1. In Solution Explorer, choose the solution.
  2. On the menu bar, choose Build Solution.

Build a single project

  1. In Solution Explorer, choose the project.
  2. On the menu bar, choose Build.

Testing with MSTest

  1. Open Test Explorer.
    • If Test Explorer is not visible, choose Test on the menu, choose Windows, and then choose Test Explorer.
  2. To run all the tests in the solution, choose Run All.

Usage

API

IrohaDotNet

CreateKeyPair

using IrohaDotNet;

KeyPair keyPair = Iroha.CreateKeyPair();
//===> keypair.PublicKey : Ed25519 public key encoded by base64
//===> keypair.PrivateKey : Ed25519 private key encoded by base64

Sign

using IrohaDotNet;

string signature = Iroha.Sign(keyPair, message);
//===> signature : signature encoded by base64

Verify

using IrohaDotNet;

bool verify = Iroha.Verify(publicKey, signature, message);
//===> verify : true if the correct message

Sha3_256

using IrohaDotNet;

string hash = Sha3Util.Sha3_256("");
//===> hash : "a7ffc6f8bf1ed76651c14756a061d662f580ff4de43b49fa82d80a4b80f8434a"

Sha3_384

using IrohaDotNet;

string hash = Sha3Util.Sha3_384("");
//===> hash : "0c63a75b845e4f7d01107d852e4c2485c51a50aaaa94fc61995e71bbee983a2ac3713831264adb47fb6bd1e058d5f004"

Sha3_512

using IrohaDotNet;

string hash = Sha3Util.Sha3_512("");
//===> hash : "a69f73cca23a9ac5c8b567dc185a756e97c982164fe25859e0d1dcc1475c80a615b2123af1f5f94c11e3e9402c3ac558f500199d95b6d3e301758586281dcd26"

Author

adachij2002

License

Copyright 2017 Jin Adachi.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

iroha-dotnet's People

Contributors

ryjones avatar adachij2002 avatar takemiyamakoto avatar

Watchers

James Cloos 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.