GithubHelp home page GithubHelp logo

smartlets / in3 Goto Github PK

View Code? Open in Web Editor NEW

This project forked from blockchainsllc/in3-legacy

0.0 1.0 0.0 3.37 MB

Typescript-version of the in3 client

License: Other

TypeScript 99.45% Dockerfile 0.55%

in3's Introduction

INCUBED Client

Forks Stars License: AGPL v3

INCUBED (in3) is a minimal verification client for blockchain networks.

Most blockchains, such as Ethereum, require a client to connect to their blockchain network. Often, these clients require a very high bandwidth or constant computation. While this is possible to perform on laptops or desktop systems, mobile devices struggle to meet these requirements. Currently the solution of choice is to use a light client on mobile devices. While this works for mobile phones, most IoT devices are unable to run light clients. Connecting an IoT device to a remote node enables even low-performance IoT devices to be connected to blockchain. However, by using distinct remote nodes the advantages of a decentralized network are undermined introducing a single point of failure. The Trustless Incentivized Remote Node Network, in short INCUBED, would make it possible to establish a decentralized and secure network of remote nodes, enabling trustworthy and fast access to blockchain for a large number of low-performance IoT and mobile devices.

in3_image

A more detailed explanation of in3 can be found in the concept on readthedocs.

Platforms

INCUBED can be used in different ways

Stack Size Code Base Use Case
TS/ JavaScript 2.7MB https://github.com/slockit/in3 WebApplication (decentralized RPC-Client in the Browser) or Mobile Applications
C/C++ 200kB https://github.com/slockit/in3-c IoT-Devices, can be integrated nicely on many micro controllers (like [zephyr-supported boards] (https://docs.zephyrproject.org/latest/boards/index.html) ) or anny other C/C++ -Application
Java 705kB https://github.com/slockit/in3-c Java-Implementation of a native-wrapper
Docker 2.6MB https://github.com/slockit/in3 For replacing existing clients with this docker and connect to incubed via localhost:8545 without the need to change the architecture
bash 400kB https://github.com/slockit/in3-c the in3-commandline utils can be used directly as executable within bash-script or on the shell

other Languages (like C#, Python, Go, Rust) will be supported soon (until then you can simply use the shared library directly).

For information on the in3-node, sources on github or readthedocs will help you.

For information on the in3 client implementation in C, please go in3-c or API Documentation.

Installation and Usage

npm

Installing the in3-client is as easy as installing other modules:

npm install --save in3

Import incubed with:

import In3Client from "in3"

Example

// import in3-Module
import In3Client from 'in3'
import * as web3 from 'web3'

async function demo() {

    // use the In3Client as Http-Provider
    const web3 = new Web3(new In3Client({
        proof         : 'standard',
        signatureCount: 1,
        requestCount  : 2,
        chainId       : 'mainnet'
    }).createWeb3Provider())

    // use the web3
    const block = await web.eth.getBlockByNumber('latest')
}

Detailed examples with usage of in3 in typescript programs can be found here.

Features

in3 Remote Client Light Client
Failsafe connection ✔️ ✔️
Automatic Nodelist updates ✔️ ✔️
Partial nodelist ✔️ ✔️
Multi-chain support ✔️ ✔️
Full verification of JSON-RPC methods ✔️
IPFS support ✔️ ✔️
Caching support ✔️
Proof-Levels ✔️
POA Support ✔️ ✔️ ✔️
Database setup size-minutes 0-instant️ 0-instant ~50Mb-minutes️
Uses IoT devices,Mobile,browser️ Mobile,browser️️ PC,Laptop️

Resources

Contributors welcome!

We at Slock.it believe in the power of the open source community. Feel free to open any issues you may come across, fork the repository and integrate in your own projects. You can reach us on various social media platforms for questions.

Twitter Blog Youtube LinkedIn Gitter

Got any questions?

Contact us on Gitter or send us an email at [email protected]

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.