Title
The first independent cryptocurrency blockchain distributed for all devices
Context
The original BitCoin document created by Satoshi Nakamoto envisages storing all the transactions carried out in a public ledger.
The transactions carried out represent exchanges of a virtual currency.
The technology on which the public ledger is stored is the blockchain.
The blockchain system plans to link the next information to be memorized to the last using hashing algorithms.
Each block is therefore linked by a reference to its previous one.
It is therefore possible to validate all the ledger starting from the last available information and scroll back through each block.
Being a distributed peer-to-peer system, the longest block is validated using a Proof-Of-Work based algorithm.
In particular, the algorithm chosen for the POW scale on the mathematical calculation of the hashes thus bringing a POW that requires CPU to be guaranteed.
In a short time the CPU computational cost required the implementation of the same in ASIC and made it impossible for the normal home desktop PCs to generate the block to insert in the blockchain.
History
The evolution of bitcoin since 2009 has led to the evolution of cryptocurrencies for alternative purposes: thanks to ethereum it is possible to execute the code by consuming GAS for a fee. To date, the computational cost and the Proof-Of-Work system has determined the maximum scalability of blockchain to date based on this paradigm.
Cryptocurrencies
Cryptocurrencies are an example of data that are stored in blockchains and have the following advantages:
- Peer to Peer: the ledger is distributed all over the world
- Anonymity: the transaction is attributable to a specific address
- Feeding transactions: the cost of the transaction is scaled by the amount of the storage itself
Similar solutions
https://storj.io | Blockchain-based, end-to-end encrypted, distributed object storage, where only you have access to your data. |
https://ethereum.org | decentralized platform that runs smart contracts |
https://www.enigma.co | Decentralizing Privacy: Using Blockchain to Protect Personal Data |
https://www.bigchaindb.com | The scalable blockchain database powering IPDB |
https://recordskeeper.co | Blockchain is changing the way we store documents, data & any other information on the Cloud |
https://www.ascribe.io | Lock in attribution, securely share and trace where your digital work spreads |
MILK
The memorization blockchain MILK has the goal to be performed and maintained by every single device on the market, for example IOT devices, Smartwatch that have limited computing power.
In order to be used by every single device, Proof-of-Relay is used instead of Proof-of-Work.
This algorithm is based on the latency of information propagation.
The MILK blockchain is therefore designed to store short user information and distribute it as fast as possible to connected peers.
MILK Goals
We designed MILK to be a blockchain independent of cryptocurrencies: the information stored in the MILK blockchain is unrelated to cryptocurrencies.
Having the possibility to insert short information in every single block, it is possible to create a synchronization between several blockchain at the same time.
Goals:
- Blockchain distributed on all systems that can be connected to the internet so far available
- Storage of generic user information, potentially independent of cryptocurrencies
- Propagation of information as fast as possible
MILK is agnostic to the information exchanged so much that it is possible to parallelize several branches of independent blockchains synchronized with each other.
Applications
In general, there are three types of applications on top of MILK.
The first category is financial applications, providing users with more powerful ways of managing and entering into contracts using their intellectual properties.
The second category is semi-financial applications, where PI is involved but there is also a heavy non-monetary side to what is being done; a perfect example is self-enforcing bounties for solutions to computational problems. Finally, there are applications such as online voting and decentralized governance that are not financial at all.
Examples
- Score storage: during gaming session
- School degree and exam scoring
- Intellectual property footprints
- ESCROW foodprints
- Public Key storage: giving the ID your customer can retrieve the key
- Public election voting storage
- Streaming keys
- Streaming drive
Naming
MILK | it’s the friendly name of the blockchain, My Ledger Keeper |
DropContent | contains the user information to be stored inside the blockchain |
Drop | Blockchain “block” that encapsulates the content, it contains the chain pointers |
Fly | Current “on the fly” queue to be validated: aka the relay train |
Ledger | Confirmed and stored blockchain blocks |
Ledger
The Ledger consists of blocks connected to each other, each block can occupy a maximum of 1KB. In each block the end user can store the following information: nickname, notes and signature.
The block is valid because it is connected to its previous block: the parent field contains the previous hash.
To block the content is then made the total hash of the block that will go in the blockchain.
Each block in technical jargon is called a drop.
Proof of something
All distributed blockchains are based on the concept of “non-trust” of the peers who are part of it, to protect themselves and thus “balance” the consensus of the quorum are activated by the impediments to generate blocks. The most famous system in the world and implemented is the Proof-of-Work: use heavy CPU calculations so that a malicious peer “alone” can not infect the network.
MILK differs from other blockchain because it implements a different algorithm for the validation of information: “Proof-of-Relay”, translated into Italian “relay test”
Peer to peer
The mesh peer to peer on which MILK is based is a proprietary algorithm available independently: in this case our goal was to find a transport system that respects the following:
- Also works under firewalls
- Works by proxy or standard https or http protocols
- Very low propagation times
- Implementable in all devices on the market (eg smartwatch, IOT, smartphone, routers ect …)
- Easy
The opensource library can be used on a standalone project.
Using this system of connection between the nodes has added the possibility to distribute the blockchain also on websites based on http and https transport protocols.
Nodes capabilities
The nodes can perform the following tasks:
Client semplice | Create and send the contents of the blockchain to the nearest “proxy” node |
Proxy | Nodo che è in grado di connettersi alla rete ricevendo connessioni dai client |
Archive | Memorizza in modo persistente le informazioni del ledger |
Ledger Rule | Concorre al quorum per la validazione di un nuovo blocco |
I vari funzionamenti possono essere eseguiti contemporaneamente dal dispositivo in base alle proprie risorse hardware, è anche possibile eseguire la stessa funzionalità su più blockchain in parallelo.
Network connectivity
La mesh di MILK è composta da peer connessi attraverso diversi protocolli di trasporto:
- https
- http
- TCP
- UDP
- Telegram
Each proxy peer is able to accept incoming clients and propagates received packets to the peer to peer mesh. The mesh topology is a dynamic graph that can close.
The dynamism of the graph depends on the following factors:
- Availability of current node resources
- Propagation speed of the adjacent node
- The adjacent node leads to a closed path
- Weights of the adjacent arc coming from the neural network MMNN (Milk Mesh Neural Network) which is adapted to maintain a 51% consensus quorum
Boot
The peer to peer works through a first network scouting node: this node contains the addresses of the peers to which to connect to enter the official MILK network.
Since MILK is an opensource project it is possible to have a proper {bootStrapUrl}: we do not recommend the forkchain fork, while we suggest to change the blockchain encryption key {blockchainKey}.
Per avere i valori aggiornati, collegatevi a https://web.myledgerkeeper.com
Mesh messages
Download last block | Legge l’ultimo ID memorizzato nella blockchain |
Put Block | Invia un nuovo blocco al fly per essere memorizzato nella blockchain |
Get Fly | I validatori utilizzano il Proof-of-Relay per completare e ordinare il fly |
Validate Fly | Quando il fly raggiunge il 51% di quorum questo viene scritto nel ledger |
Download Ledger | Download in stream del ledger |
Supported devices
The design of this blockchain aims to support the highest number of device models. Check compatibility through ready-made packages or integration of open source SDK libraries.
Blockchain
The peculiarity of the MILK blockchain is that the blocks generated by the clients are not memorized immediately inside the ledger but they are waiting in an ordered queue.
The “fly” is the ordered queue system that contains blocks still not written in the ledger: the fly is the system used to guarantee the Proof-Of-Relay algorithm.
Blockchain data
Esempio di pacchetto root memorizzato nella blockchain:
{ "chain": "13a521de668f88a4d5410ab25ae4aad8e4769d84b20b98509c5a781236816f4f", "parent": null, "id": "0.1775515249", "content": "{\"signature\":\"307322dc6eedbd871001cf85c5c08b40047a2df71e8194d5d0d1c6a8e884ec58\",\"nickname\":\"Official Milk Blockchain\",\"note\":\"Blockchain root\"}", "hash": "8add1413631b631c44c8480f86bd1be4fa5df28d0c7864b8d08042bc0c4bcdc0" }
The other packages will contain valued “parent” with the previous hash. Each block can occupy up to 1KB in JSON format: this also includes the transition toSHA-512.
Blockchain flow
The insertion of an information in the public ledger follows a flow determined by the following steps:
Proof of Relay
The fly is downloaded into the ledger when it gets a validation from the quorum above to the 51%.
Blocks validation
Block validation takes place at the “fly” phase. Fly is the train of blocks that has the value of major equal to FlyMajor = LastBlockMajor + 1. In this queue all the “Drop” received in a period of time are present in an orderly growing manner.
The fly is validated in one of the following hypotheses:
- Drop number exceeds the configuration parameter (for example 7KB)
- The time since the first Drop has exceeded the configuration parameter (for example 1 minute)
- The time since the last Drop exceeded the configuration parameter (for example 1 minute)
- Node resources are running out
The Drop Fly once validated will be stored in the ledger:
Fee
The proof-of-relay algorithm provides a remuneration based on the reliability of the nodes currently available in the MILK network. Some important parameters are as follows:
- Bonus: propagation speed
- Malus: number of Drop added in the Fly
- Bonus: persistent storage of information (number of times to download the ledger fragment)
The bonuses are accumulated to guarantee an expense in storing information in the ledger.
Scalability
In order to scale we thought of the multi-chain system that is already present in the 1.2 version of the protocol.
Foreign blockchains
The MILK blockchain is agnostic to the stored information, this allows to synchronize the proof-of-releay with other external systems.
Plugin
The MILK system is based on a protocol implemented in API libraries available on all languages and development environments. It is therefore possible to write a code routine executed in your dedicated node so that it can implement one of the following ideas:
- Adding a single package or submerged in a Fly with external blockchain information
- Add the ethereum token information within DropContent
- Synchronize the MILK blockchain with centralized systems such as NTP time stamps
- Encrypt or countersign the information stored within the same MILK
Multiple chains
We designed MILK to be agnostic to the information stored inside: it is possible, but not recommended, to add blocks signed by different {blockchainKey} so you can take advantage of all the topology of the MILK network by storing proprietary content verifiable only from your {blockchainKeyCustom} .
The advantage of supporting from multiple version 1.2 the multiple chain is to resist temporary or perpetual fork of the blockchain: we are the first blockchain able to remain intact even with more active fork inside it.
Foreign partners
By writing a plugin that synchronizes the MILK blockchain with Bitcoin or Ethereum it is possible to integrate payment systems or cryptocurrencies within MILK.
Chain alloy
The glue that allows to make a “braid” of blockchain is the proof-of-relay system: at the time of writing the crossed hashes of all active blockchains will be computed.
Notes, References and Further Reading
Notes
References
Ethereum White paper | https://github.com/ethereum/wiki/wiki/White-Paper |