Giter Site home page Giter Site logo

the07 / cryptokernel Goto Github PK

View Code? Open in Web Editor NEW

This project forked from mit-dci/cryptokernel

0.0 1.0 0.0 9.99 MB

A SDK for implementing blockchain-based digital currencies

Home Page: https://cryptokernel.org

License: GNU General Public License v3.0

Dockerfile 1.45% Lua 7.05% Shell 0.28% C++ 54.38% C 36.84%

cryptokernel's Introduction

CryptoKernel

CryptoKernel is a C++ library intended to help create blockchain-based digital currencies. It contains modules for key-value storage with JSON, peer-to-peer networking, ECDSA & Schnorr key generation, signing and verifying, big number operations, logging and a blockchain class for handling a Bitcoin-style write-only log. Designed to be object-oriented and easy to use, it provides transaction scripting with Lua 5.3, custom consensus algorithms (e.g Proof of Work, Authorised Verifier Round-Robin) and custom transaction types.

K320

We have used Cryptokernel to implement an experimental digital currency called K320. Its name derives from its monetary policy – Milton Friedman’s K% rule at a rate of 320 basis points or 3.2% growth per year (https://en.wikipedia.org/wiki/Friedman%27s_k-percent_rule). This known rate removes the need for trust in the decisions of a central authority, making monetary supply policy completely transparent. K320 is designed to build up the initial money supply relatively quickly then switch to the K% rule for monetary growth.

In K320, blocks are produced every 2.5 minutes. The block reward starts at 100 coins per block, diminishing for 8 years until the year 2025 at block 1,741,620 and a supply of 68,720,300 coins. At this point the block reward switches to a constant 3.2% per year. At 210,240 blocks per year, that is .0000152% of total supply per block as reward. For example, the first block reward after the switch to the constant reward rate will be ~10.45; (0.000000152*68,720,300). For a more detailed description of this see: https://github.com/mit-dci/CryptoKernel/blob/master/src/client/multicoin.cpp#L80

K320 is currently implemented by default when you run the CryptoKernel software.

Building on Ubuntu 16.04

./installdeps.sh
premake5 gmake2
make

The resulting binary will be in the bin/Static/Debug directory.

It is also possible to compile with other options. See make help and premake5 --help for a list.

Usage

See the source files in src/client/ for example usage. CryptoKernel ships with a Proof of Work coin built-in called K320 that works out of the box. For more information about the API check the documentation.

To launch CryptoKernel as K320 with its default setup, simply write:

./ckd

To get a list of command line RPC commands use:

./ckd help

To make ckd run in daemon mode use:

./ckd -daemon

API Reference

Build the documentation with doxyblocks.

premake5 gmake2 --with-docs
make

Roadmap

(in no particular order)

  • Load external contract code to avoid duplication when propagating contracts
  • Standardised address format (not just public keys)
  • BFT consensus module
  • Raft consensus module
  • Proof of Stake consensus module
  • HD key generation

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.