Table of Contents
What is Massa’s global vision?
2022 marks the time when modular blockchains are carried in triumph, victorious over the hard-to-be-solvable trilemma of the blockchain. However, 2022 can also be the year when decentralization, security and scalability are no longer contradictory, but work together in a common direction. This is the approach that Massa labs offers us.
Based on the principle of a multi-threaded oriented acyclic graph (DAG), this new protocol heralds the new era of monolithic blockchains. More efficient and secure, but above all more decentralized. And we will quickly realize that for Massa labs decentralization is not subject to any concessions. Before addressing the subject, a brief overview of the team.
Initially, the Massa blockchain was a research project led by 3 friends passionate about mathematics, now co-founders. This is a point that stands out strongly in this project through the latent perfectionism with which each step is conducted.
- Sébastien Forestier: CEO – PhD in Artificial Intelligence
- Damir Vodenicarevic: CTO – PhD in Fundamental Physics
- Adrien Laversanne-Finot: CSO – Doctor of Quantum Information
Since the first research in 2017, the team has grown and now has a dozen core devs, supplemented by support & compliance services. Proof of the strong competence and prescience of this team, the 23rd edition of the i-Lab innovation competition organized by the Ministry of Higher Education, was the opportunity to reward the Massa project with the innovation prize.
What level of decentralization can we expect?
Endowed with a strong cypherpunk vision, the founders infused this DNA into their protocol until they formed its genesis. Massa labs aims to become the blockchain with the highest level of decentralization in the ecosystem.
As Damir mentions, “a blockchain can be considered a bad database, slow and expensive. One of the major contributions is decentralization. To move away from this attribute is to lose sight of one’s first asset. »
To do this, the choice of a Proof-of-Stake consensus was preferred. The latter has the advantage in terms of decentralization of not conferring an economy of scale as allowed by proof-of-work through the acquisition of mining equipment.
However, PoS has inherent Achilles heels related to distribution, the concentration of the native corner, the accessibility of the necessary hardware setup, as well as the amount to staker in order to become a validator. A small number of validators would mean that a large part of security is left out.
Very special care is therefore taken in the distribution of Massa. The distribution of the latter will soon be made public, however no entity will be able to acquire more than 1% of the supply. What we currently know:
- During the private sale, €5 million was raised, an amount divided between 100 investment funds and individuals in 18 countries;
- The entire Massa team (including the founders) will take over a (very) minority part, with vesting over several years;
- During 2022 during the public sale, the acquisition will be made on the basis of KYC and will be capped in order to ensure maximum decentralization;
- Same rules regarding the rewards awarded to the community that participated in the testnet and to future ambassadors.
The amount to stake to become a validator is also a sensitive variable within a PoS consensus. The amount of corner required is still being studied, but the team obviously wants to make it accessible to as many people as possible, the objective being to have a maximum of validators.
Even if no computational calculation is required in the consensus chosen by Massa, being paired with a P2P network still requires a hardware setup.
Currently during the testnet, it is possible to rotate a node on a simple Raspberry Pi. In the long term, it is advisable to have a more substantial equipment, while remaining affordable, consisting of:
- 8 CPUs (4 physical)
- 16 GB RAM
- 1 TB of storage
In addition, avoiding a concentration of validation power is a source of particular attention.
Within the testnet, for example, geographical concentration is examined. The scoring of each of the beta testers is therefore negatively impacted if their node is hosted in a common place to many others. This is to increase the independence of the network.
During the mainnet, vigilance regarding concentration will take another form, that concerning custodians. Based on market analyses that expose the control of certain entities over various PoS networks, Massa’s team is studying legal remedies that can prevent this. The objective is to limit the potential influence of these custodians, an influence that often comes from individuals who delegate their stake.
The primary objective of the project therefore remains decentralization in what it represents most noble, this also induces respect for the community and its choices. Governance via DAO is therefore to be expected, allowing users to decide on-chain on certain major points of the protocol.
What is the Nakamoto coefficient?
As has just been presented, the level of decentralization may depend on a large number of factors. However, one coefficient tries to quantify it: the Nakamoto coefficient. The current calculation is inspired by the Lorenz curve & the Gini coefficient, combining them with a subsystem-based approach.
A blockchain is then interpreted as a system divided into a set of subsystems. It is then necessary to determine how many entities it is necessary to control in each subsystem for a risk of collusion to appear in the entire system.
The subsystems selected in the equation are:
- Plurality of validators (who gets the rewards?)
- Diversity of clients (by codebase) available to access the network
- Number of developers (per commit over a given period of time)
- Exchange quantity (in volume)
- Decentralization of nodes (by number) geographically
- Supply concentration level (by address)
This coefficient allows us to obtain an objective basis on which to compare different networks.
Various studies (including that of Arxiv in 2021) base their calculation on the plurality of validators, assigning a score of 4 to Bitcoin and 3 to Ethereum.
On this same basis, the Massa blockchain obtains thanks to its approach a theoretical score of 1,000.
What is the technical architecture?
The Massa solution, formerly known as Blockclique, is based on a DAG multithreading structure. This results in a monolithic blockchain with sharding of transactions resulting in executions on parallel threads, without final reconciliation. Let’s dissect these terms:
First of all to be able to fully understand what a monolithic blockchain (otherwise called integrated blockchain) implies, it is necessary to present the 3 major components that make up a blockchain. Consensus, Execution and Availability.
- Consensus defines the canonical truth about the data of a blockchain and helps secure the network.
- Execution represents the calculations necessary for the evolution of the state of a blockchain.
- Data availability refers to the data hosted by each of the nodes.
Unlike modular blockchains, of which ethereum’s new architecture is the figurehead, monolithic blockchains perform all the tasks previously mentioned on layer 1. Thus, consensus, execution and availability of data are ensured by the same layer, which is the case of Bitcoin for example.
- The main advantage of monolithic structures is their resilience. Indeed, their security is directly dependent on the sum of the resources that work to comply with the rules set by the consensus. In the case of monolithic blockchains, all resources secure the main network.
- Their main disadvantage, on the other hand, is their much greater submission to the blockchain trilemma.
- The main advantage of modular structures is their high scalability. Naturally, when you divide the tasks and assign each of the parts to specific actions, you gain efficiency.
- The main disadvantage of these blockchains is the other side of the coin of the point previously mentioned. When the network is divided into multiple subunits, it is easier for an attacker to achieve a sufficient ratio to an attack on one of the subunits. The resistance of a chain is always judged by the strength of its weakest link.
“Sharding parallel thread transactions”
In order to be functional and prevent the risk of double spending, the vast majority of blockchains operate in sequential DAG.
For the more technical: One vortex per sequence and a direct edge linked to each vortex.
For the less technical: The blocks are produced one by one and are linked by a parent/child bond.
In this classic layout (e.g. Bitcoin), the referring blockchain is the one that is the highest (whose sum of difficulty is the highest).
The validators therefore make sure to take the pending transactions in the mempool in order to build a valid block according to the consensus in force. Then once the block is formed, it is propagated to the entire network and becomes the last block of the referring blockchain. It comes down to having a single channel, a single thread on which everything is done.
The Massa team then came to propose a new architecture, composed of 32 threads, which makes it possible to parallelize the structure of the data.
Each block created in a specific thread has 32 parent blocks.
So the problem you might say is: how do you prevent an address from making a double expense by executing the same transaction in two different threads?
To do this, Massa allows each of the addresses to make its expenses only through a single thread. This is defined by the first bits of the address.
Each thread thus has transactions with only one address range as input defined and as output all potential addresses on the network.
A unique property is emerging: the ability to create forks and desynchronizations without the risk of blockchain corruption.
Where in standard blockchains it is necessary for nodes to have the last block to be able to create the next one, with the Massa blockchain validators can work on a new block without owning all the last ones.
- JOE has 50 Massa and its address is set as transmitter on thread 1
- BOB has 10 Massa and its address is set as transmitter on thread 4
- JOE wants to send 5 Massa to Bob.
A validator is responsible for creating the new block (N1) of thread 1.
It retrieves the transaction from JOE in the mempool.
As long as the last block (N) of thread 1 has a state where the joe balance is > 5 Massa, the transaction will be valid.
The validator can therefore take as parents the last known blocks of the other 31 threads, even if forks are present, because in none of them the balance of JOE could have decreased. At best, JOE’s balance can only be higher.
Indeed JOE can only spend his balance through thread 1. However, it can receive coins and tokens from transactions from all threads.
In this example, JOE will credit the BOB balance of 5 Massa via a transaction on thread 1. When BOB in turn wants to spend all or part of his balance, he will do so via thread 4.
This solution therefore ensures sequential consistency of debits for each address, while allowing a slight desynchronization of credits.
“Without final reconciliation”
Other solutions such as Elastico, Zilliqa, Iota also offer approaches based on transaction sharding.
However, within these protocols, the nodes must regularly agree on the reference blockchain and canonical blocks in order to avoid a double expense. This is called a reconciliation phase, often managed by a centralized process. Beyond having already proven its security limits with the Iota shutdown in 2020, this reconciliation phase significantly restricts the benefits of the parallelization offered by transaction sharding.
What is the potential of the network?
To begin with, a few figures:
- Number of theoretical transactions: 10,000 transactions/second
- Average network block time: 2 blocks/second
- Average block time per thread: 1 block every 16 seconds
Finalization time: This is a vast topic, because what is often compared between the various protocols is the nominal purpose. In the event that everything goes well, therefore, a few seconds are enough to know if a transaction has been concluded (validated by the network). However, for an extreme purpose of 10^-15 over 100 years, during an attack with 40% of the stake that would break the system, it takes a finality of 30 to 40 seconds.
For an acceptable purpose that can be used daily, 15 to 20 seconds is enough.
The size of the transaction will define the final time considered appropriate by the parties involved.
Choice of interpreter: Web assembly The Web assembly
allows you to reach a much larger community of developers. The team envisions that this interpreter will eventually become the standard since it allows many developers to develop in the language they are most comfortable with. A project depends in part on its community of developers, so this is a major point.
In addition, the multi-threaded structure proposed by Massa has other potential advantages. Even if they are not currently envisaged, it is technically possible:
- To have threads with reduced block sizes and a higher frequency so a shorter purpose.
- To have threads under interpret EVM and others in Web assembly.
- To have threads specific to certain uses and transactions.
What are the new perspectives?
The advantages of Massa labs do not stop at an ultra decentralized and scalable blockchain, the value proposition goes beyond these two aspects.
The real Web3
One of the current problems when we talk about web3 is that it is often a centralized website that allows you to interact with smart contracts via a connected wallet. And it is these access points that can be problematic, due to immutability and security much less strong than a blockchain.
A source of potential flaw that Badger DAO would have done well without in December 2021, whose front-end attack cost $ 120 million. Ideally it is everyone’s responsibility to check at each of our connections that a website interacting with a blockchain has not been altered. This is obviously not viable.
The idea of Massa labs is to solve this problem by pushing the concept of ENS (Ethereum Name Service) further. Why just have an address to send coins and tokens to? Could we not use this system to display decentralized websites?
The solution is therefore to store the critical elements of a website directly in a smart contract. Here we are not talking about the design, the UI / UX, but the interaction of the site with smart contracts, minimal elements that are in themselves small.
- You type the domain name in your search bar;
- The plug-in will be connected to a Massa node (yours preferred);
- Via the plug-in, the browser will search the blockchain for the smart contract containing the website’s infrastructure;
- The browser will then interpret the data through the plug-in and display the desired site;
- The same guarantees of immutability that users place in smart contracts are present on the access points to them;
- The functionalities of the website will then be directly dependent on the functions of the smart contract and translated by ABI.
Currently a POC has been created and will soon be offered to the community during the testnet phase.
Here we will touch on the quintessence of a totally decentralized web3 experience. From the resolution of the domain name, to the interaction with the website and the hosting of the latter, nothing will go through centralized servers.
Autonomous smart contract
This is one of the great innovations proposed by Massa. Currently a smart contract does not run without external appeal of one of its functions. In order to overcome this, these autonomous smart contracts will themselves make function calls on their program according to pre-established rules.
Today, to perform this kind of action in an automated way, it requires the support of an off-chain infrastructure, such as bots that will send requests to the node.
This novelty directly related to the infrastructure of the blockchain, at the heart of the protocol, gives the possibility of paying an amount of gas upstream for future executions. This amounts to a form of asynchronous programming of smart contracts and the prospects for on-chain automation are enormous.
To name just a few examples:
- Event functions such as “Wake up such smart contract in 5 blocks and execute the X function”.
- Automated actions such as “If Y takes place on smart contract 1; make a call to the Z function on the smart contract 2, then on the smart contract 3… ».
- Lending/borrowing protocols where an automatic liquidation of collateralized positions will be triggered via an on-chain bot.
- On-chain arbitration bots between several DeFi protocols. Automatic reproductions of NFTs as made “manually” on the model of Cryptokitties.
The execution environment of these autonomous smart contracts will also be unprecedented since Massa labs has set up its own VM.
To deploy the full potential of this innovation, the team also plans to build some applications based on the core team, as well as launch a Grants program to attract other developers.
A demonstration was made during the Paris Blockchain Week that it is possible to reproduce at home. To do this:
- Install the Massa wallet as an extension (https://github.com/massalabs/massa-wallet)
- Create a wallet directly on the extension (compatible with Firefox and Chrome)
- Go to the URL massa://gameoflife
The demo may take a little time to load. Note that everything that will appear then runs on the Massa blockchain. No centralized servers are called during this process.
What is the current state of the network?
At the time of writing, the network has just started episode 10 of its Testnet. We can go back to the results of episode 9.
The network peaked at 5,900 validator nodes! This is more than 90% of the mainnets of current blockchains. This is largely a direct consequence of the weak hardware setup required to spin a node.
In addition, interest in the ecosystem is growing and it testifies to the sensitivity of users on decentralization issues.
The rise of the network is also seen by a 20% increase in transactions per second compared to the previous episode: 1200 txps on average. The end of the episode also gave rise to a more advanced performance test, rising to 2600 txps for more than 2000 nodes remaining operational at these levels.
One of the major evolutions of this episode concerns the mechanism of propagation of transactions (version 9.2). This allowed an optimization of the amount of bandwidth used, as well as excellent stability by blurring any predominance of the CPU over the RAM.
Episode 10 (ongoing)
With its version 10.1, the network offers here its most stable and powerful version ever designed by addressing an optimization to slight RAM leaks observed in previous episodes.
It is with this approach of continuous improvement, transparent and close to its users that the team works the iterations of the network until the release of the Mainnet.
What about the Mainnet
Many steps are still to be taken before the launch of the planned mainnet Q4 2022. The exact roadmap should be released in Q2 2022
The solution proposed by Massa labs is promising both through its deep architecture based on a multi-threaded DAG and via the innovations provided.
The strong point of this blockchain is its response to the trilemma presented by Vitalik, mixing decentralization and maximum security with a layer 1 that can handle up to 10,000 transactions / second.
The team was particularly active during events in April. It was possible to meet them at:
- General talk on April 8 at PiX Lille;
- Workshop at the PBWS from 13 to 14 April in Paris;
- Hackaton Kryptosphere from 23 to 24 April in Lyon.
Many other events will be organized and will be announced on the official discord.
All information related to the launch of a node is available on the official github.
And if you want to join the adventure, they recruit!