<metaname="description"content="Abstract # This document specifies Claro: a Byzantine, fault-tolerant, binary decision agreement algorithm that utilizes bounded memory for its execution. Claro is a novel variant of the Snow family providing a probabilistic leaderless BFT consensus algorithm that achieves metastablity via network sub-sampling. We present an application context of the use of Claro in an efficient, leaderless, probabilistic permission-less consensus mechanism. We outline a simple taxonomy of Byzantine adversaries, leaving explicit explorations of to subsequent publication.">
<metaproperty="og:description"content="Abstract # This document specifies Claro: a Byzantine, fault-tolerant, binary decision agreement algorithm that utilizes bounded memory for its execution. Claro is a novel variant of the Snow family providing a probabilistic leaderless BFT consensus algorithm that achieves metastablity via network sub-sampling. We present an application context of the use of Claro in an efficient, leaderless, probabilistic permission-less consensus mechanism. We outline a simple taxonomy of Byzantine adversaries, leaving explicit explorations of to subsequent publication."/>
<p>This document specifies Claro: a Byzantine, fault-tolerant, binary decision
agreement algorithm that utilizes bounded memory for its execution.
Claro is a novel variant of the Snow family providing a probabilistic
leaderless BFT consensus algorithm that achieves metastablity via
network sub-sampling. We present an application context of the use of
Claro in an efficient, leaderless, probabilistic permission-less
consensus mechanism. We outline a simple taxonomy of Byzantine
adversaries, leaving explicit explorations of to subsequent
publication.</p>
<p>NOTE: We have renamed this variant to <code>Claro</code> from <code>Glacier</code> in order to disambiguate from a previously released research endeavor by <ahref="https://arxiv.org/pdf/2210.03423.pdf">Amores-Sesar, Cachin, and Tedeschi</a>. Their naming was coincidentally named the same as our work but is sufficiently differentiated from how ours works.</p>
<h1id="motivation">
Motivation
<aclass="anchor"href="#motivation">#</a>
</h1>
<p>This work is a part of a larger research endeavor to explore highly scalable Byzantine Fault Tolerant (BFT) consensus protocols. Consensus lies at the heart of many decentralized protocols, and thus its characteristics and properties are inherited by applications built on top. Thus, we seek to improve upon the current state of the art in two main directions: base-layer scalability and censorship resistance.</p>
<p>Avalanche has shown to exibit the former in a production environment in a way that is differentiated from Nakamoto consensus and other Proof of Stake (PoS) protocols based in practical Byzantine Fault Tolerant (pBFT) methodologies. We aim to understand its limitations and improve upon them.</p>
<h2id="background">
Background
<aclass="anchor"href="#background">#</a>
</h2>
<p>Our starting point is Avalanche’s Binary Byzantine Agreement algorithm, called Snowball. As long as modifications allow a DAG to be constructed later on, this simplifies the design significantly. The DAG stays the same in principle: it supports confidence, but the core algorithm can be modeled without.</p>
<p>The concept of the Snowball algorithm is relatively simple. Following is a simplified description (lacking some details, but giving an overview). For further details, please refer to the <ahref="https://assets.website-files.com/5d80307810123f5ffbb34d6e/6009805681b416f34dcae012_Avalanche%20Consensus%20Whitepaper.pdf">Avalanche paper</a>.</p>
<ol>
<li>The objective is to vote yes/no on a decision (this decision could be a single bit, or, in our DAG use case, whether a vertex should be included or not).</li>
<li>Every node has an eventually-consistent complete view of the network. It will select at random k nodes, and will ask their opinion on the decision (yes/no).</li>
<li>After this sampling is finished, if there is a vote that has more than an <code>alpha</code> threshold, it accumulates one count for this opinion, as well as changes its opinion to this one. But, if a different opinion is received, the counter is reset to 1. If no threshold <code>alpha</code> is reached, the counter is reset to 0 instead.</li>
<li>After several iterations of this algorithm, we will reach a threshold <code>beta</code>, and decide on that as final.</li>
</ol>
<p>Next, we will proceed to describe our new algorithm, based on Snowball.</p>
<p>We have identified a shortcoming of the Snowball algorithm that was a perfect starting point for devising improvements. The scenario is as follows:</p>
<ul>
<li>There is a powerful adversary in the network, that controls a large percentage of the node population: 10% to ~50%.</li>
<li>This adversary follows a strategy that allows them to rapidly change the decision bit (possibly even in a coordinated way) so as to maximally confuse the honest nodes.</li>
<li>Under normal conditions, honest nodes will accumulate supermajorities soon enough, and reach the <code>beta</code> threshold. However, when an honest node performs a query and does not reach the threshold <code>alpha</code> of responses, the counter will be set to 0.</li>
<li>The highest threat to Snowball is an adversary that keeps it from reaching the <code>beta</code> threshold, managing to continuously reset the counter, and steering Snowball away from making a decision.</li>
</ul>
<p>This document only outlines the specification to Claro. Subsequent analysis work on Claro (both on its performance and how it differentiates with Snowball) will be published shortly and this document will be updated.</p>
<p>The Claro consensus algorithm computes a boolean decision on a
proposition via a set of distributed computational nodes. Claro is
a leaderless, probabilistic, binary consensus algorithm with fast
finality that provides good reliability for network and Byzantine
fault tolerance.</p>
<h2id="algorithmic-concept">
Algorithmic concept
<aclass="anchor"href="#algorithmic-concept">#</a>
</h2>
<p>Claro is an evolution of the Snowball Byzantine Binary Agreement (BBA) algorithm, in which we tackle specifically the perceived weakness described above. The main focus is going to be the counter and the triggering of the reset. Following, we elaborate the different modifications and features that have been added to the reference algorithm:</p>
<ol>
<li>Instead of allowing the latest evidence to change the opinion completely, we take into account all accumulated evidence, to reduce the impact of high variability when there is already a large amount of evidence collected.</li>
<li>Eliminate the counter and threshold scheme, and introduce instead two regimes of operation:
<ul>
<li>One focused on grabbing opinions and reacting as soon as possible. This part is somewhat closer conceptually to the reference algorithm.</li>
<li>Another one focused on interpreting the accumulated data instead of reacting to the latest information gathered.</li>
</ul>
</li>
<li>Finally, combine those two phases via a transition function. This avoids the creation of a step function, or a sudden change in behavior that could complicate analysis and understanding of the dynamics. Instead, we can have a single algorithm that transfers weight from one operation to the other as more evidence is gathered.</li>
<li>Additionally, we introduce a function for weighted sampling. This will allow the combination of different forms of weighting:
<ul>
<li>Staking</li>
<li>Heuristic reputation</li>
<li>Manual reputation.</li>
</ul>
</li>
</ol>
<p>It’s worth delving a bit into the way the data is interpreted in order to reach a decision. Our approach is based conceptually on the paper <ahref="https://cis.temple.edu/~pwang/Publication/confidence.pdf">Confidence as Higher-Order Uncertainty</a>, which describes a frequentist approach to decision certainty. The first-order certainty, measured by frequency, is caused by known positive evidence, and the higher-order certainty is caused by potential positive evidence. Because confidence is a relative measurement defined on evidence, it naturally follows comparing the amount of evidence the system knows with the amount that it will know in the near future (defining “near” as a constant).</p>
<p>Intuitively, we are looking for a function of evidence, <strong><code>w</code></strong>, call it <strong><code>c</code></strong> for confidence, that satisfies the following conditions:</p>
<ol>
<li>Confidence <code>c</code> is a continuous and monotonically increasing function of <code>w</code>. (More evidence, higher confidence.)</li>
<li>When <code>w = 0</code>, <code>c = 0</code>. (Without any evidence, confidence is minimum.)</li>
<li>When <code>w</code> goes to infinity, <code>c</code> converges to 1. (With infinite evidence, confidence is maximum.)</li>
</ol>
<p>The paper describes also a set of operations for the evidence/confidence pairs, so that different sources of knowledge could be combined. However, we leave here the suggestion of a possible research line in the future combining an algebra of evidence/confidence pairs with swarm-propagation algorithm like the one described in <ahref="http://replicated.cc/files/schmebulock.pdf">this paper</a>.</p>
<h3id="initial-opinion">
Initial opinion
<aclass="anchor"href="#initial-opinion">#</a>
</h3>
<p>A proposal is formulated to which consensus of truth or falsity is
desired. Each node that participates starts the protocol with an
opinion on the proposal, represented in the sequel as <code>NO</code>, <code>NONE</code>,
and <code>YES</code>.</p>
<p>A new proposition is discovered either by local creation or in
response to a query, a node checks its local opinion. If the node can
compute a justification of the proposal, it sets its opinion to one of
<code>YES</code> or <code>NO</code>. If it cannot form an opinion, it leaves its opinion as
<code>NONE</code>.</p>
<p>For now, we will ignore the proposal dissemination process and assume all nodes participating have an initial opinion to respond to within a given request. Further research will relax this assumption and analyze timing attacks on proposal propagation through the network.</p>
<p>The node then participates in a number of query rounds in which it
solicits other node’s opinion in query rounds. Given a set of <code>N</code>
leaderless computational nodes, a gossip-based protocol is presumed to
exist which allows members to discover, join, and leave a weakly
transitory maximally connected graph. Joining this graph allows each
node to view a possibly incomplete node membership list of all other
nodes. This view may change as the protocol advances, as nodes join
and leave. Under generalized Internet conditions, the membership of
the graph would experience a churn rate varying across different
time-scales, as the protocol rounds progress. As such, a given node
may not have a view on the complete members participating in the
consensus on a proposal in a given round.</p>
<p>The algorithm is divided into 4 phases:</p>
<ol>
<li>Querying</li>
<li>Computing <code>confidence</code>, <code>evidence</code>, and <code>accumulated evidence</code></li>
<li>Transition function</li>
<li>Opinion and Decision</li>
</ol>
<!-- raw HTML omitted -->
<!-- raw HTML omitted -->
<!-- raw HTML omitted -->
<h3id="setup-parameters">
Setup Parameters
<aclass="anchor"href="#setup-parameters">#</a>
</h3>
<p>The node initializes the following integer ratios as constants:</p>
<pretabindex="0"><code># The following values are constants chosen with justification from experiments
# performed with the adversarial models
#
confidence_threshold
<-- 1
# constant look ahead for number of rounds we expect to finalize a
# decision. Could be set dependent on number of nodes
# visible in the current gossip graph.
look_ahead
<-- 19
# the confidence weighting parameter (aka alpha_1)
certainty
<-- 4 / 5
doubt ;; the lack of confidence weighting parameter (aka alpha_2)
<-- 2 / 5
k_multiplier ;; neighbor threshold multiplier
<-- 2
;;; maximal threshold multiplier, i.e. we will never exceed