Logo
Cardano Ecosystem

Input Output

10/14/2024

·

225 views


Ouroboros Peras: the next step in the journey of Cardano’s protocol

Ouroboros Peras (henceforth, Peras) is an extension of the Ouroboros Praos protocol that addresses the problem of transactions’ settlement horizon, that is, the point in time when the probability of a transaction being reverted becomes negligible. Shorter settlement times improve security, usability and efficiency in blockchain systems.

Ouroboros Peras: the next step in the journey of Cardano’s protocol

Ouroboros Peras (henceforth, Peras) is an extension of the Ouroboros Praos protocol that addresses the problem of transactions’ settlement horizon, that is, the point in time when the probability of a transaction being reverted becomes negligible. Shorter settlement times improve security, usability and efficiency in blockchain systems.

The key concept behind Peras is the use of stake-based voting to boost the weight of blocks on which a majority of stake pool operators (SPOs) agree. The chain selection rule is then modified to select the heaviest chain instead of the longest one.

This blog post reflects on the relevance of settlement time in blockchain environments, and more specifically in the Cardano ecosystem, and describes what Peras is and how it works.

Scaling Cardano

The anticipated growth of the Cardano ecosystem necessitates the implementation of a series of scaling solutions. Specifically, new versions of the Ouroboros protocol are being developed to enhance layer 1 performance. These advancements address areas not covered by the existing scaling solutions and are crucial for supporting Cardano's expanding network.

Our work on Peras has also given Input | Output the opportunity to establish and drive a new innovation process, designed to minimize the time required to take a research idea to implementation via simulations and rapid prototyping. The goal? To maintain the robustness and rigor of fundamental research, while recognizing the fast-moving pace of blockchain ecosystem development. Thanks to this process, a detailed CIP was drafted (along with AGDA specifications) before the paper itself was formally published.

Existing scaling solutions: Hydra and Mithril

Hydra is a layer 2 scaling solution designed to enhance the Cardano blockchain. It enables a group of participants to take a portion of the Cardano ledger state (layer 1), process it off-chain (layer 2), and then seamlessly reintegrate it back into the main blockchain (layer 1). A crucial feature of Hydra is that the ledger model used off-chain is identical to that used on the mainchain, ensuring a type of ‘isomorphism’. This, combined with the off-chain processing, allows for high throughput, low latency, and cost efficiency, while ensuring robust security by using the main blockchain as a fallback.

The first protocol in the Hydra family is the Hydra head protocol. Hydra heads are isomorphic versions of multi-party state channels, meaning that all participating nodes share equal responsibility for maintaining and evolving the off-chain state. In contrast, Hydra tails, which are currently in the early stages of research, aim to extend the concept of isomorphic layer-2 solutions to roll-up-like protocols. These ‘asymmetric’ protocols involve one or multiple servers processing transactions off-chain on behalf of clients.

Mithril is a stake-based multi-signature scheme that leverages the existing Cardano network to provide certified snapshots of all or part of the blockchain state. The primary application of Mithril is to facilitate faster bootstrapping of Cardano nodes. Instead of verifying every block published since the genesis block, which is time-consuming, a joining node can start from a certified snapshot. These snapshots are therefore particularly useful for synchronization between applications, sidechains, or light wallets.

Peras & Leios

While Hydra enables fast and high-throughput transaction processing on layer 2, neither Hydra nor Mithril address the throughput and latency of the Cardano mainnet. This has led to the development of Ouroboros Peras (the focus of this blog) and Leios, new versions of the Ouroboros protocol. Peras aims to shorten settlement times, while Leios focuses on maximizing the use of available network bandwidth. Together, these protocols will enhance the user experience by allowing more transactions to be recorded and settled more quickly on the blockchain. In a recent video, Input | Output’s chief scientist, Aggelos Kiayias, describes this suite of new technologies that promise to significantly improve Cardano's scalability.

Ouroboros and settlement

The importance of fast settlement

‘Fast settlement’ refers to the rapid decrease in the probability of a transaction being reverted as time progresses. The usability of a blockchain is directly linked to how quickly it can settle transactions. For example, when using blockchain to pay for goods, it is important to wait long enough for the payment transaction to settle before transferring the goods. For inexpensive items, such as a cup of coffee, one might accept a higher probability of failure for a shorter wait time. However, for high-value items like a Lamborghini, one should wait until the probability of payment being reverted is extremely low. In both scenarios, the faster the probability of reversion decreases, the more convenient and practical the blockchain is for payments.

Another critical use case for fast settlement is bridges to sidechains, which enable users to transfer funds from the main chain to a sidechain. Since reverting a transaction related to such transfers can disrupt the correct functioning of the sidechain, it is crucial to wait until the probability of reversion is minimal. Therefore, the faster the settlement guaranteed by the mainchain, the more efficient and reliable the bridge becomes.

In summary, fast settlement is essential for the overall usefulness and practicality of a blockchain.

How does settlement work in Cardano?

The Cardano blockchain is powered by a protocol known as Ouroboros. In Praos, the current version of Ouroboros, new blocks are added probabilistically. In each (time) slot, SPOs participate in a lottery for the right to produce a new block, with their chances of winning proportional to the amount of stake they represent. Currently, Cardano's protocol parameters dictate that a new block is created approximately every 20 slots. These new blocks are then propagated across the network and adopted by other nodes following the longest chain principle. This means that when an SPO receives an extended chain with a new block, it adopts this new chain as its own if – and only if – the new chain is longer than their current chain.

In Cardano, a block that is currently part of the longest chain can be ‘reverted’ if a longer chain appears that ‘forks’ before said block and therefore does not include it. Such forking can occur when multiple SPOs are elected to create a block simultaneously, for example. In practice, however, forks resulting from simultaneous block production are usually short-lived due to tie-breaking mechanisms that select between equal-length chains. A more significant concern is long forks resulting from attacks on the system, such as private-chain attacks. In such an attack, adversarial nodes, possibly representing a substantial fraction of the total stake, build a secret chain and release it only when the public chain catches up with the private chain, thus causing long forks.

Crucially, the deeper a block is in the longest chain, the less likely it is to be reverted. With Praos, the waiting time for a small probability of reversion can range from minutes to many hours, depending on the desired level of security and the assumed strength of the adversary. Peras will significantly shorten this waiting time, as explained below.

Difference between finality and settlement

In the context of blockchain ecosystems, it is important to understand the difference between finality and settlement. Blockchains powered by protocols based on Byzantine Fault Tolerant (BFT) computing, such as Algorand, achieve ‘finality’, meaning that blocks are generally confirmed almost instantly and, once confirmed, become a permanent part of the chain's history. This finality is robust, with only a very small probability that the entire protocol might fail. Note that such a failure would mean the protocol is broken permanently.

Conversely, Nakamoto-based protocols, such as Ouroboros, achieve ‘settlement’. This means that the likelihood of a block remaining part of the blockchain's history increases as more blocks are built on top of it. Technically, however, there is always a possibility, albeit very small, that a block could be reverted due to a reorganization of the chain, even if it is deeply embedded. Importantly, in contrast to BFT-type protocols, such a reversion is not considered a failure that breaks the protocol permanently.

Thus, while BFT protocols offer immediate and enduring confirmation with a small overall error probability, Nakamoto protocols provide a probabilistic assurance that becomes more robust as the blockchain grows. Probabilistic settlement allows for other desirable properties, such as self-healing, which will be described in future blog posts.

How Peras enables fast settlement

The main idea underlying Peras is to enhance Praos with a mechanism where SPOs implicitly signal their support for blocks slightly behind the tip of their preferred chain. Votes increase the weight of a chain (the ‘base’ weight being given by the chain’s blocks), and parties select the heaviest chain they see as their preferred chain.

Under good circumstances – a performant network and low corruption – most votes are likely to coincide on a single block and provide a weight boost to any chain that includes this block. It is crucial for the safety of Peras, however, that there be sufficient agreement in each voting round. That is, there must be a block that garners more than a certain threshold amount of the votes, a so-called quorum. The threshold is chosen in such a way that at most a single block may reach a quorum and such that there is a significant vote gap between the quorum block and any other block. Absent a quorum, a voting gap cannot be guaranteed, and an attacker may use the voting layer to split the honest parties and thereby gain an advantage.

Therefore, after a failed voting round, Peras enters a cooldown period during which voting is suspended and the protocol essentially proceeds as Praos. The length of the cooldown period must be sufficiently long to ensure that any adversarial advantage gained from an unfavorable distribution of votes in the failed round will be neutralized by the end of cooldown.

There is a tradeoff between the boost provided by votes and the length of the cooldown period. The higher the boost, the higher the potential damage caused by an unsuccessful voting round, and thus, the longer before voting may be resumed.

In practice, the Cardano network is highly performant and has proven impressively resilient even to physical failures. Furthermore, at any given time, close to 100% of delegated stake is online, and, to the best of our knowledge, no attacks on Praos involving significant amounts of stake have been reported since the beginning of the Shelley era, which suggests that a vast majority of SPOs follow the protocol. Under the reasonable assumption that these conditions persist, one can therefore project Peras would continuously enjoy fast settlement, without the need for cooldowns.

Evidence-based, open-source engineering

The development and implementation of Peras fit in with IO's evidence and research-based, open-source approach to engineering.

Every new technological advancement for Cardano starts with a series of ideas and research papers. The subsequent development and idea maturation process includes different stages.

The ideas postulated are formally specified through algorithms and proofs. Theorem proving helps prove key security properties, such as chain growth and common prefixes, and also builds a foundation for more formal methods-based research and validation.

All these components undergo testing via prototype implementation in Haskell before creating a live simulation and a technical model to analyze the behavior of the entire network. The simulation enables both IO and the community to visualize and simulate the dynamic properties of the protocol. The resulting data is gathered, analyzed, and offered to the community through regular updates and reports.

The ultimate goal of these processes, and the continuous development of the Ouroboros protocol series, is solving real-world problems through blockchain technology.

Open source

Concurrently, open source design enables software creators to accelerate development from the outset, leverage a community of experts to expand knowledge and scope, and use well-tested, peer-reviewed code.

All this translates into an array of benefits that can be grouped into the following categories:

Quicker innovation and growth

Open source means that the building blocks for constructing and developing a software project are already there, ready to be used, which significantly cuts start-up time. Creators can simply take the code and use it for their projects right away. Open source-based developments can innovate and grow quickly.

Faster, secure, and more transparent development

Any new creators joining an existing open source project do so with the assurance that the code has been thoroughly tested and verified by many others. This assurance, and the inherent transparency of open source, support fast and secure development.

Community-based support and collaboration

Strong, widespread, and active communities support better software quality and more consistent releases.

In such an environment, new ideas spread quicker, and if any issues or bugs arise, the community works to resolve them. A strong community built around a software project creates a sense of connection and the instinct to work towards a common goal. Involved community members tend to be supportive of each other and share suggestions for new use cases, for example.

How to get involved

The development of Peras has progressed rapidly. This means that the core ideas and algorithms have been established, and formal specifications and prototypes are being developed and tested. There's still much work to be done before Peras can be considered for deployment on the Cardano mainnet. However, Peras has been part of a new development methodology that seeks to minimize the time between fundamental research and ultimate deployment through fast prototyping approaches being pioneered by Input | Output. As a result, for the first time, a protocol update has been drafted as a CIP before the publication of the research paper.

The evolution of Peras will be a collaborative effort with the Cardano community, and it's being actively discussed across various committees and working groups of Intersect. We encourage developers, researchers, and enthusiasts to explore the resources above, participate in discussions on the Discord server, and contribute their expertise to the project.

If you're interested in becoming part of the Peras project, please use these resources:

 


 

AD

SNEKbot by DexHunter on CARDANO

Cardano's Telegram Trading Bot live on Cardano mainnet!TRADE NOW!


Read Original Article on Input Output

ORIGINAL SOURCE

https://iohk.io/en/blog/posts/2024/10/14...

Disclaimer: Cardano Feed is a Decentralized News Aggregator that enables journalists, influencers, editors, publishers, websites and community members to share news about the Cardano Ecosystem. User must always do their own research and none of those articles are financial advices. The content is for informational purposes only and does not necessarily reflect our opinion.


An image that says Learn Blockchain technology and get ahead in the industry with a link to the Cardano Academy.

More from Input Output

See more
Announcing XSY: accelerate economic value
Input Output
Announcing XSY: accelerate economic value

03/06/2024

·

1.2K views

Related News

See more

Featured News

See more



    DEFAULTENGLISH (EN)SPANISH (ES)RUSSIAN (RU)GERMAN (DE)ITALIAN (IT)POLISH (PL)HUNGARIAN (HU)JAPANESE (JA)THAI (TH)ARABIC (AR)VIETNAMESE (VI)PERSIAN (FA)GREEK (EL)INDONESIAN (ID)ROMANIAN (RO)KOREAN (KO)FRENCH (FR)CZECH (CS)PORTUGUESE (PT)TURKISH (TR)