Abstract
Abstract
A public ledger is a tamperproof sequence of data that can be read and augmented by everyone. Public ledgers have innumerable and compelling uses. They can secure, in plain sight, all kinds of transactions —such as titles, sales, and payments— in the exact order in which they occur. Public ledgers not only curb corruption, but also enable very sophisticated applications —such as cryptocurrencies and smart contracts. They stand to revolutionize the way a democratic society operates. As currently implemented, however, they scale poorly and cannot achieve their potential. Algorand is a truly democratic and efficient way to implement a public ledger. Unlike prior implementations based on proof of work, it requires a negligible amount of computation, and generates a transaction history that will not "fork" with overwhelmingly high probability. Algorand is based on (a novel and super fast) message-passing Byzantine agreement. For concreteness, we shall describe Algorand only as a money platform.
摘要
公共分类账是一个防篡改的数据序列,每个人都可以读取和扩充。 公共分类账有无数且引人注目的用途。他们可以在众目睽睽之下保护各种 交易(例如所有权、销售和付款)按照其发生的确切顺序排列。 公共分类账不仅可以遏制腐败,还可以实现非常复杂的应用程序,例如 加密货币和 smart contracts。他们致力于彻底改变民主社会的方式 运行。然而,按照目前的实施情况,它们的扩展性很差,无法发挥其潜力。 Algorand 是一种真正民主且有效的实施公共账本的方式。 与之前不同 基于工作量证明的实现,它需要的计算量可以忽略不计,并且 生成的交易历史不会以极高的概率“分叉”。 Algorand 基于(一种新颖且超快的)消息传递拜占庭协议。 具体而言,我们仅将 Algorand 描述为一个货币平台。
Introduction
Introduction
Money is becoming increasingly virtual. It has been estimated that about 80% of United States dollars today only exist as ledger entries [5]. Other financial instruments are following suit. In an ideal world, in which we could count on a universally trusted central entity, immune to all possible cyber attacks, money and other financial transactions could be solely electronic. Unfortunately, we do not live in such a world. Accordingly, decentralized cryptocurrencies, such as Bitcoin [29], and "smart contract" systems, such as Ethereum, have been proposed [4]. At the heart of these systems is a shared ledger that reliably records a sequence of transactions, ∗This is the more formal (and asynchronous) version of the ArXiv paper by the second author [24], a paper itself based on that of Gorbunov and Micali [18]. Algorand's technologies are the object of the following patent applications: US62/117,138 US62/120,916 US62/142,318 US62/218,817 US62/314,601 PCT/US2016/018300 US62/326,865 62/331,654 US62/333,340 US62/343,369 US62/344,667 US62/346,775 US62/351,011 US62/653,482 US62/352,195 US62/363,970 US62/369,447 US62/378,753 US62/383,299 US62/394,091 US62/400,361 US62/403,403 US62/410,721 US62/416,959 US62/422,883 US62/455,444 US62/458,746 US62/459,652 US62/460,928 US62/465,931
as varied as payments and contracts, in a tamperproof way. The technology of choice to guarantee such tamperproofness is the blockchain. Blockchains are behind applications such as cryptocurrencies [29], financial applications [4], and the Internet of Things [3]. Several techniques to manage blockchain-based ledgers have been proposed: proof of work [29], proof of stake [2], practical Byzantine fault-tolerance [8], or some combination. Currently, however, ledgers can be inefficient to manage. For example, Bitcoin's proof-of-work approach (based on the original concept of [14]) requires a vast amount of computation, is wasteful and scales poorly [1]. In addition, it de facto concentrates power in very few hands. We therefore wish to put forward a new method to implement a public ledger that offers the convenience and efficiency of a centralized system run by a trusted and inviolable authority, without the inefficiencies and weaknesses of current decentralized implementations. We call our approach Algorand, because we use algorithmic randomness to select, based on the ledger constructed so far, a set of verifiers who are in charge of constructing the next block of valid transactions. Naturally, we ensure that such selections are provably immune from manipulations and unpredictable until the last minute, but also that they ultimately are universally clear. Algorand's approach is quite democratic, in the sense that neither in principle nor de facto it creates different classes of users (as "miners" and "ordinary users" in Bitcoin). In Algorand "all power resides with the set of all users". One notable property of Algorand is that its transaction history may fork only with very small probability (e.g., one in a trillion, that is, or even \(10^{-18}\)). Algorand can also address some legal and political concerns. The Algorand approach applies to blockchains and, more generally, to any method of generating a tamperproof sequence of blocks. We actually put forward a new method —alternative to, and more efficient than, blockchains— that may be of independent interest. 1.1 Bitcoin's Assumption and Technical Problems Bitcoin is a very ingenious system and has inspired a great amount of subsequent research. Yet, it is also problematic. Let us summarize its underlying assumption and technical problems —which are actually shared by essentially all cryptocurrencies that, like Bitcoin, are based on proof-of-work. For this summary, it suffices to recall that, in Bitcoin, a user may own multiple public keys of a digital signature scheme, that money is associated with public keys, and that a payment is a digital signature that transfers some amount of money from one public key to another. Essentially, Bitcoin organizes all processed payments in a chain of blocks, \(B_1, B_2, \ldots\), each consisting of multiple payments, such that, all payments of \(B_1\), taken in any order, followed by those of \(B_2\), in any order, etc., constitute a sequence of valid payments. Each block is generated, on average, every 10 minutes. This sequence of blocks is a chain, because it is structured so as to ensure that any change, even in a single block, percolates into all subsequent blocks, making it easier to spot any alteration of the payment history. (As we shall see, this is achieved by including in each block a cryptographic hash of the previous one.) Such block structure is referred to as a blockchain. Assumption: Honest Majority of Computational Power Bitcoin assumes that no malicious entity (nor a coalition of coordinated malicious entities) controls the majority of the computational power devoted to block generation. Such an entity, in fact, would be able to modify the blockchain,
and thus re-write the payment history, as it pleases. In particular, it could make a payment \(\wp\), obtain the benefits paid for, and then "erase" any trace of \(\wp\). Technical Problem 1: Computational Waste Bitcoin's proof-of-work approach to block generation requires an extraordinary amount of computation. Currently, with just a few hundred thousands public keys in the system, the top 500 most powerful supercomputers can only muster a mere 12.8% percent of the total computational power required from the Bitcoin players. This amount of computation would greatly increase, should significantly more users join the system. Technical Problem 2: Concentration of Power Today, due to the exorbitant amount of computation required, a user, trying to generate a new block using an ordinary desktop (let alone a cell phone), expects to lose money. Indeed, for computing a new block with an ordinary computer, the expected cost of the necessary electricity to power the computation exceeds the expected reward. Only using pools of specially built computers (that do nothing other than "mine new blocks"), one might expect to make a profit by generating new blocks. Accordingly, today there are, de facto, two disjoint classes of users: ordinary users, who only make payments, and specialized mining pools, that only search for new blocks. It should therefore not be a surprise that, as of recently, the total computing power for block generation lies within just five pools. In such conditions, the assumption that a majority of the computational power is honest becomes less credible. Technical Problem 3: Ambiguity In Bitcoin, the blockchain is not necessarily unique. Indeed its latest portion often forks: the blockchain may be —say— \(B_1, \ldots, B_k, B'_{k+1}, B'_{k+2}\), according to one user, and \(B_1, \ldots, B_k, B''_{k+1}, B''_{k+2}, B''_{k+3}\) according another user. Only after several blocks have been added to the chain, can one be reasonably sure that the first \(k + 3\) blocks will be the same for all users. Thus, one cannot rely right away on the payments contained in the last block of the chain. It is more prudent to wait and see whether the block becomes sufficiently deep in the blockchain and thus sufficiently stable. Separately, law-enforcement and monetary-policy concerns have also been raised about Bitcoin.1 1.2 Algorand, in a Nutshell Setting Algorand works in a very tough setting. Briefly, (a) Permissionless and Permissioned Environments. Algorand works efficiently and securely even in a totally permissionless environment, where arbitrarily many users are allowed to join the system at any time, without any vetting or permission of any kind. Of course, Algorand works even better in a permissioned environment. 1The (pseudo) anonymity offered by Bitcoin payments may be misused for money laundering and/or the financing of criminal individuals or terrorist organizations. Traditional banknotes or gold bars, that in principle offer perfect anonymity, should pose the same challenge, but the physicality of these currencies substantially slows down money transfers, so as to permit some degree of monitoring by law-enforcement agencies. The ability to "print money" is one of the very basic powers of a nation state. In principle, therefore, the massive adoption of an independently floating currency may curtail this power. Currently, however, Bitcoin is far from being a threat to governmental monetary policies, and, due to its scalability problems, may never be.
(b) Very Adversarial Environments. Algorand withstands a very powerful Adversary, who can (1) instantaneously corrupt any user he wants, at any time he wants, provided that, in a permissionless environment, 2/3 of the money in the system belongs to honest user. (In a permissioned environment, irrespective of money, it suffices that 2/3 of the users are honest.) (2) totally control and perfectly coordinate all corrupted users; and (3) schedule the delivery of all messages, provided that each message \(m\) sent by a honest user reaches 95% of the honest users within a time \(\lambda_m\), which solely depends on the size of \(m\). Main Properties Despite the presence of our powerful adversary, in Algorand • The amount of computation required is minimal. Essentially, no matter how many users are present in the system, each of fifteen hundred users must perform at most a few seconds of computation. • A New Block is Generated in less than 10 minutes, and will de facto never leave the blockchain. For instance, in expectation, the time to generate a block in the first embodiment is less than \(\Lambda + 12.4\lambda\), where \(\Lambda\) is the time necessary to propagate a block, in a peer-to-peer gossip fashion, no matter what block size one may choose, and \(\lambda\) is the time to propagate 1,500 200B-long messages. (Since in a truly decentralized system, \(\Lambda\) essentially is an intrinsic latency, in Algorand the limiting factor in block generation is network speed.) The second embodiment has actually been tested experimentally ( by ?), indicating that a block is generated in less than 40 seconds. In addition, Algorand's blockchain may fork only with negligible probability (i.e., less than one in a trillion), and thus users can relay on the payments contained in a new block as soon as the block appears. • All power resides with the users themselves. Algorand is a truy distributed system. In particular, there are no exogenous entities (as the "miners" in Bitcoin), who can control which transactions are recognized. Algorand's Techniques. 1. A New and Fast Byzantine Agreement Protocol. Algorand generates a new block via a new cryptographic, message-passing, binary Byzantine agreement (BA) protocol, BA⋆. Protocol BA⋆not only satisfies some additional properties (that we shall soon discuss), but is also very fast. Roughly said, its binary-input version consists of a 3-step loop, in which a player \(i\) sends a single message \(m_i\) to all other players. Executed in a complete and synchronous network, with more than 2/3 of the players being honest, with probability > 1/3, after each loop the protocol ends in agreement. (We stress that protocol BA⋆satisfies the original definition of Byzantine agreement of Pease, Shostak, and Lamport [31], without any weakenings.) Algorand leverages this binary BA protocol to reach agreement, in our different communication model, on each new block. The agreed upon block is then certified, via a prescribed number of digital signature of the proper verifiers, and propagated through the network. 2. Cryptographic Sortition. Although very fast, protocol BA⋆would benefit from further speed when played by millions of users. Accordingly, Algorand chooses the players of BA⋆to be
a much smaller subset of the set of all users. To avoid a different kind of concentration-of-power problem, each new block \(B^r\) will be constructed and agreed upon, via a new execution of BA⋆, by a separate set of selected verifiers, \(SV^r\). In principle, selecting such a set might be as hard as selecting \(B^r\) directly. We traverse this potential problem by an approach that we term, embracing the insightful suggestion of Maurice Herlihy, cryptographic sortition. Sortition is the practice of selecting officials at random from a large set of eligible individuals [6]. (Sortition was practiced across centuries: for instance, by the republics of Athens, Florence, and Venice. In modern judicial systems, random selection is often used to choose juries. Random sampling has also been recently advocated for elections by David Chaum [9].) In a decentralized system, of course, choosing the random coins necessary to randomly select the members of each verifier set \(SV^r\) is problematic. We thus resort to cryptography in order to select each verifier set, from the population of all users, in a way that is guaranteed to be automatic (i.e., requiring no message exchange) and random. In essence, we use a cryptographic function to automatically determine, from the previous block \(B^{r-1}\), a user, the leader, in charge of proposing the new block \(B^r\), and the verifier set \(SV^r\), in charge to reach agreement on the block proposed by the leader. Since malicious users can affect the composition of \(B^{r-1}\) (e.g., by choosing some of its payments), we specially construct and use additional inputs so as to prove that the leader for the \(r\)th block and the verifier set \(SV^r\) are indeed randomly chosen. 3. The Quantity (Seed) \(Q^r\). We use the the last block \(B^{r-1}\) in the blockchain in order to automatically determine the next verifier set and leader in charge of constructing the new block \(B^r\). The challenge with this approach is that, by just choosing a slightly different payment in the previous round, our powerful Adversary gains a tremendous control over the next leader. Even if he only controlled only 1/1000 of the players/money in the system, he could ensure that all leaders are malicious. (See the Intuition Section 4.1.) This challenge is central to all proof-of-stake approaches, and, to the best of our knowledge, it has not, up to now, been satisfactorily solved. To meet this challenge, we purposely construct, and continually update, a separate and carefully defined quantity, \(Q^r\), which provably is, not only unpredictable, but also not influentiable, by our powerful Adversary. We may refer to \(Q^r\) as the \(r\)th seed, as it is from \(Q^r\) that Algorand selects, via secret cryptographic sortition, all the users that will play a special role in the generation of the \(r\)th block. 4. Secret Crytographic Sortition and Secret Credentials. Randomly and unambiguously using the current last block, \(B^{r-1}\), in order to choose the verifier set and the leader in charge of constructing the new block, \(B^r\), is not enough. Since \(B^{r-1}\) must be known before generating \(B^r\), the last non-influentiable quantity \(Q^{r-1}\) contained in \(B^{r-1}\) must be known too. Accordingly, so are the verifiers and the leader in charge to compute the block \(B^r\). Thus, our powerful Adversary might immediately corrupt all of them, before they engage in any discussion about \(B^r\), so as to get full control over the block they certify. To prevent this problem, leaders (and actually verifiers too) secretly learn of their role, but can compute a proper credential, capable of proving to everyone that indeed have that role. When a user privately realizes that he is the leader for the next block, first he secretly assembles his own proposed new block, and then disseminates it (so that can be certified) together with his own credential. This way, though the Adversary will immediately realize who the leader of the next block is, and although he can corrupt him right away, it will be too late for the Adversary to influence the choice of a new block. Indeed, he cannot "call back" the leader's message no more
than a powerful government can put back into the bottle a message virally spread by WikiLeaks. As we shall see, we cannot guarantee leader uniqueness, nor that everyone is sure who the leader is, including the leader himself! But, in Algorand, unambiguous progress will be guaranteed. 5. Player Replaceability. After he proposes a new block, the leader might as well "die" (or be corrupted by the Adversary), because his job is done. But, for the verifiers in \(SV^r\), things are less simple. Indeed, being in charge of certifying the new block \(B^r\) with sufficiently many signatures, they must first run Byzantine agreement on the block proposed by the leader. The problem is that, no matter how efficient it is, BA⋆requires multiple steps and the honesty of > 2/3 of its players. This is a problem, because, for efficiency reasons, the player set of BA⋆consists the small set \(SV^r\) randomly selected among the set of all users. Thus, our powerful Adversary, although unable to corrupt 1/3 of all the users, can certainly corrupt all members of \(SV^r\)! Fortunately we'll prove that protocol BA⋆, executed by propagating messages in a peer-topeer fashion, is player-replaceable. This novel requirement means that the protocol correctly and efficiently reaches consensus even if each of its step is executed by a totally new, and randomly and independently selected, set of players. Thus, with millions of users, each small set of players associated to a step of BA⋆most probably has empty intersection with the next set. In addition, the sets of players of different steps of BA⋆will probably have totally different cardinalities. Furthermore, the members of each set do not know who the next set of players will be, and do not secretly pass any internal state. The replaceable-player property is actually crucial to defeat the dynamic and very powerful Adversary we envisage. We believe that replaceable-player protocols will prove crucial in lots of contexts and applications. In particular, they will be crucial to execute securely small sub-protocols embedded in a larger universe of players with a dynamic adversary, who, being able to corrupt even a small fraction of the total players, has no difficulty in corrupting all the players in the smaller sub-protocol. An Additional Property/Technique: Lazy Honesty A honest user follows his prescribed instructions, which include being online and run the protocol. Since, Algorand has only modest computation and communication requirement, being online and running the protocol "in the background" is not a major sacrifice. Of course, a few "absences" among honest players, as those due to sudden loss of connectivity or the need of rebooting, are automatically tolerated (because we can always consider such few players to be temporarily malicious). Let us point out, however, that Algorand can be simply adapted so as to work in a new model, in which honest users to be offline most of the time. Our new model can be informally introduced as follows. Lazy Honesty. Roughly speaking, a user \(i\) is lazy-but-honest if (1) he follows all his prescribed instructions, when he is asked to participate to the protocol, and (2) he is asked to participate to the protocol only rarely, and with a suitable advance notice. With such a relaxed notion of honesty, we may be even more confident that honest people will be at hand when we need them, and Algorand guarantee that, when this is the case, The system operates securely even if, at a given point in time, the majority of the participating players are malicious.
1.3 Closely Related work Proof-of-work approaches (like the cited [29] and [4]) are quite orthogonal to our ours. So are the approaches based on message-passing Byzantine agreement or practical Byzantine fault tolerance (like the cited [8]). Indeed, these protocols cannot be run among the set of all users and cannot, in our model, be restricted to a suitably small set of users. In fact, our powerful adversary my immediately corrupt all the users involved in a small set charged to actually running a BA protocol. Our approach could be considered related to proof of stake [2], in the sense that users' "power" in block building is proportional to the money they own in the system (as opposed to —say— to the money they have put in "escrow"). The paper closest to ours is the Sleepy Consensus Model of Pass and Shi [30]. To avoid the heavy computation required in the proof-of-work approach, their paper relies upon (and kindly credits) Algorand's secret cryptographic sortition. With this crucial aspect in common, several significant differences exist between our papers. In particular, (1) Their setting is only permissioned. By contrast, Algorand is also a permissionless system. (2) They use a Nakamoto-style protocol, and thus their blockchain forks frequently. Although dispensing with proof-of-work, in their protocol a secretly selected leader is asked to elongate the longest valid (in a richer sense) blockchain. Thus, forks are unavoidable and one has to wait that the block is sufficiently "deep" in the chain. Indeed, to achieve their goals with an adversary capable of adaptive corruptions, they require a block to be \(\text{poly}(N)\) deep, where \(N\) represents the total number of users in the system. Notice that, even assuming that a block could be produced in a minute, if there were \(N = 1M\) users, then one would have to wait for about 2M years for a block to become \(N^2\)-deep, and for about 2 years for a block to become \(N\)-deep. By contrast, Algorand's blockchain forks only with negligible probability, even though the Adversary corrupt users immediately and adaptively, and its new blocks can immediately be relied upon. (3) They do not handle individual Byzantine agreements. In a sense, they only guarantee "eventual consensus on a growing sequence of values". Theirs is a state replication protocol, rather than a BA one, and cannot be used to reach Byzantine agreement on an individual value of interest. By contrast, Algorand can also be used only once, if so wanted, to enable millions of users to quickly reach Byzantine agreement on a specific value of interest. (4) They require weakly synchronized clocks. That is, all users' clocks are offset by a small time \(\delta\). By contrast, in Algorand, clocks need only have (essentially) the same "speed". (5) Their protocol works with lazy-but-honest users or with honest majority of online users. They kindly credit Algorand for raising the issue of honest users going offline en masse, and for putting forward the lazy honesty model in response. Their protocol not only works in the lazy honesty model, but also in their adversarial sleepy model, where an adversary chooses which users are online and which are offline, provided that, at all times, the majority of online users are honest.2 2The original version of their paper actually considered only security in their adversarial sleepy model. The original version of Algorand, which precedes theirs, also explicitly envisaged assuming that a given majority of the online players is always honest, but explicitly excluded it from consideration, in favor of the lazy honesty model. (For instance, if at some point in time half of the honest users choose to go off-line, then the majority of the users on-line may very well be malicious. Thus, to prevent this from happening, the Adversary should force most of his corrupted players to go off-line too, which clearly is against his own interest.) Notice that a protocol with a majority of lazy-but-honest players works just fine if the majority of the users on-line are always malicious. This is so, because a sufficient number of honest players, knowing that they are going to be crucial at some rare point in time, will elect not to go off-line in those moments, nor can they be forced off-line by the Adversary, since he does not know who the crucial honest players might be.
(6) They require a simple honest majority. By contrast, the current version of Algorand requires a 2/3 honest majority. Another paper close to us is Ouroboros: A Provably Secure Proof-of-Stake Blockchain Protocol, by Kiayias, Russell, David, and Oliynykov [20]. Also their system appeared after ours. It also uses crytpographic sortition to dispense with proof of work in a provable manner. However, their system is, again, a Nakamoto-style protocol, in which forks are both unavoidable and frequent. (However, in their model, blocks need not as deep as the sleepy-consensus model.) Moreover, their system relies on the following assumptions: in the words of the authors themselves, "(1) the network is highly synchronous, (2) the majority of the selected stakeholders is available as needed to participate in each epoch, (3) the stakeholders do not remain offline for long periods of time, (4) the adaptivity of corruptions is subject to a small delay that is measured in rounds linear in the security parameter." By contrast, Algorand is, with overwhelming probability, fork-free, and does not rely on any of these 4 assumptions. In particular, in Algorand, the Adversary is able to instantaneously corrupt the users he wants to control.
介绍
金钱变得越来越虚拟。据估计,美国约 80% 今天的美元仅作为分类帐条目 [5] 存在。其他金融工具也纷纷效仿。 在一个理想的世界中,我们可以依靠一个普遍信任的中央实体,免疫 对于所有可能的网络攻击,金钱和其他金融交易可以完全电子化。 不幸的是,我们并不生活在这样的世界中。因此,去中心化的加密货币,例如 如Bitcoin [29],以及“smart contract”系统,例如Ethereum,已被提议为[4]。 在 这些系统的核心是一个共享账本,它可靠地记录一系列交易, *这是第二作者[24]的ArXiv论文的更正式(异步)版本,一篇论文 它本身基于 Gorbunov 和 Micali [18] 的理论。 Algorand 的技术是以下目标的对象 专利申请: US62/117,138 US62/120,916 US62/142,318 US62/218,817 US62/314,601 PCT/US2016/018300 US62/326,865 62/331,654 US62/333,340 US62/343,369 US62/344,667 US62/346,775 US62/351,011 US62/653,482 US62/352,195 US62/363,970 US62/369,447 US62/378,753 US62/383,299 US62/394,091 US62/400,361 US62/403,403 US62/410,721 US62/416,959 US62/422,883 US62/455,444 US62/458,746 US62/459,652 US62/460,928 US62/465,931以防篡改的方式,与付款和合同一样多样化。 选择的技术 保证这种防篡改的是 blockchain。 区块链支持以下应用程序 加密货币 [29]、金融应用 [4] 和物联网 [3]。几种技巧 已提议管理基于 blockchain 的账本:工作量证明 [29]、权益证明 [2]、 实用的拜占庭容错 [8] 或某种组合。 然而,目前分类账的管理效率较低。例如,Bitcoin 的 proof-of-work 方法(基于 [14] 的原始概念)需要大量计算,是浪费 并且扩展性很差[1]。此外,它事实上将权力集中在极少数人手中。 因此,我们希望提出一种新的方法来实现公共分类账,提供 由受信任且不可侵犯的权威机构运行的集中式系统的便利性和效率,无需 当前分散实施的低效和弱点。我们称我们的方法为 Algorand,因为我们根据目前构建的账本使用算法随机性进行选择, 一组验证者,负责构建下一个有效交易块。自然地, 我们确保此类选择可证明不受操纵且不可预测,直到 最后一刻,但也表明他们最终是普遍清楚的。 Algorand 的方法是相当民主的,从某种意义上说,无论是原则上还是事实上 创建不同类别的用户(如 Bitcoin 中的“矿工”和“普通用户”)。在 Algorand “所有 权力属于所有用户”。 Algorand 的一个值得注意的特性是,它的交易历史记录可能只分叉非常小的交易。 概率(例如,万亿分之一,甚至 10−18)。 Algorand 还可以解决一些法律问题 和政治担忧。 Algorand 方法适用于 blockchains,更一般地,适用于生成 防篡改的块序列。我们实际上提出了一种新方法——替代,并且 比 blockchains 更有效,这可能具有独立利益。 1.1 Bitcoin 的假设和技术问题 Bitcoin是一个非常巧妙的系统,启发了大量后续研究。然而,它 也是有问题的。让我们总结一下它的基本假设和技术问题—— 实际上,基本上所有基于 proof-of-work 的加密货币都共享这些加密货币,例如 Bitcoin。 对于此摘要,只需回想一下,在 Bitcoin 中,用户可能拥有多个公钥 在数字签名方案中,金钱与公钥相关联,并且付款是 将一定数量的资金从一个公钥转移到另一个公钥的数字签名。本质上, Bitcoin 将所有已处理的付款组织在区块链中,B1、B2、. 。 ., 每个由多个组成 付款,使得 B1 的所有付款以任何顺序进行,然后是 B2 的所有付款以任何顺序进行, 等等,构成了一系列有效的支付。每个区块平均每 10 分钟生成一次。 这个区块序列是一条链,因为它的结构是为了确保任何变化,即使是 在单个块中,渗透到所有后续块中,从而更容易发现任何更改 付款历史记录。 (正如我们将看到的,这是通过在每个块中包含一个加密货币来实现的 前一个的hash。)这样的块结构被称为blockchain。 假设:诚实的大多数计算能力 Bitcoin 假设没有恶意 实体(也不是协调的恶意实体的联盟)控制着大部分计算 专门用于区块生成的电力。事实上,这样的实体能够修改 blockchain,从而根据需要重写付款历史记录。特别是,它可以进行付款\(\wp\), 获得所支付的利益,然后“抹掉”任何 \(\wp\) 的痕迹。 技术问题1: 计算浪费 Bitcoin 的 proof-of-work 阻止方法 生成需要大量的计算。目前,仅有几百人 系统中数千个公钥,前500名最强大的超级计算机只能聚集 仅占 Bitcoin 玩家所需总计算能力的 12.8%。这个 如果更多的用户加入系统,计算量将大大增加。 技术问题2:权力集中 今天,由于数量过多 需要计算,用户试图使用普通桌面(更不用说一个 手机),预计会赔钱。事实上,为了用普通计算机计算一个新的块, 计算所需电力的预期成本超出了预期奖励。 仅使用专门构建的计算机池(除了“挖掘新块”之外不执行任何操作),一台 可能期望通过生成新区块来获利。因此,今天事实上有两个 不相交的用户类别:仅进行支付的普通用户和专门的矿池, 只搜索新块。 因此,截至最近,块的总计算能力不足为奇。 一代仅集中在五个池内。在这种情况下,假设大多数 诚实的计算能力变得不那么可信。 技术问题3:歧义 在 Bitcoin 中,blockchain 不一定是唯一的。确实 它的最新部分经常分叉:blockchain 可能是——比如说——B1,. 。 。 , Bk, B′ k+1,B′ k+2,根据 一个用户,B1,. 。 。 , Bk, B′′ k+1,B′′ k+2,B′′ 根据另一位用户的说法,k+3。只有在几个块之后 已添加到链中,是否可以合理确定前 k + 3 个块将是相同的 对于所有用户。因此,人们不能立即依赖最后一个区块中包含的付款 链条。更谨慎的做法是等待,看看区块是否足够深入 blockchain 因此足够稳定。 另外,还提出了对 Bitcoin.1 的执法和货币政策担忧。 1.2 Algorand,简而言之 设置 Algorand 在非常艰难的环境中工作。简而言之, (a) 免许可和许可环境。 Algorand 甚至可以高效、安全地工作 在完全无需许可的环境中,允许任意多个用户加入 系统随时进行,无需任何审查或任何形式的许可。当然,Algorand 有效 在许可的环境中甚至更好。 1Bitcoin 付款提供的(伪)匿名可能会被滥用于洗钱和/或融资 犯罪分子或恐怖组织。传统的纸币或金条,原则上可以提供完美的 匿名性,应该会带来同样的挑战,但这些货币的物理性大大减慢了货币流通速度 转移,以便执法机构能够进行一定程度的监督。 “印钞”的能力是民族国家最基本的权力之一。因此,原则上,大规模 采用独立浮动的货币可能会削弱这种力量。然而,目前 Bitcoin 还远未实现 对政府货币政策构成威胁,但由于其可扩展性问题,可能永远不会构成威胁。(b) 非常敌对的环境。 Algorand 抵御非常强大的对手,他可以 (1) 在任何他想要的时间立即腐蚀任何他想要的用户,前提是,在 无许可环境下,系统中2/3的资金属于诚实用户。 (在一个 许可的环境下,不考虑钱,只要有2/3的用户是诚实的就够了。) (2) 完全控制并完美协调所有腐败用户;和 (3) 安排所有消息的传送,前提是每条消息 m 由诚实用户发送 在 \(\lambda\)m 时间内达到 95% 的诚实用户,这完全取决于 m 的大小。 主要性能 尽管存在我们强大的对手,在 Algorand • 所需的计算量极小。本质上,无论有多少用户 在系统中,一千五百个用户中的每一个必须执行最多几秒钟的操作 计算。 • 新区块在 10 分钟内生成,并且实际上永远不会离开 blockchain。 例如,预计第一个实施例中生成块的时间会更少 比 Λ + 12.4\(\lambda\),其中 Λ 是在点对点八卦中传播区块所需的时间 时尚,无论选择什么块大小,\(\lambda\) 是传播 1,500 个 200Blong 消息的时间。 (因为在真正去中心化的系统中,Λ 本质上是一种内在的延迟,在 Algorand 块生成的限制因素是网络速度。)第二个实施例有 实际上经过实验测试(通过?),表明在不到 40 的时间内生成了一个块 秒。 此外,Algorand 的 blockchain 的分叉概率可以忽略不计(即小于 1) 以一万亿计),因此用户可以在新区块中立即进行支付 块出现。 • 所有权力都属于用户自己。 Algorand 是一个真正的分布式系统。特别是, 不存在可以控制哪些交易的外源实体(如 Bitcoin 中的“矿工”) 被认可。 Algorand 的技术。 1. 一种新的、快速的拜占庭协议。 Algorand 通过生成一个新块 一种新的加密、消息传递、二进制拜占庭协议 (BA) 协议,BA⋆。协议 BA⋆不仅满足一些附加属性(我们将很快讨论),而且速度也非常快。 粗略地说,它的二进制输入版本由一个 3 步循环组成,其中玩家 i 发送一个 向所有其他玩家发送消息 mi。在完整同步的网络中执行,具有更多 超过 2/3 的玩家是诚实的,概率 > 1/3,在每次循环后协议结束 协议。 (我们强调协议 BA⋆满足拜占庭协议的原始定义 Pease、Shostak 和 Lamport [31] 的版本,没有任何削弱。) Algorand 利用这个二进制 BA 协议在我们不同的通信中达成一致 模型,在每个新块上。然后通过规定数量的区块来验证商定的区块 适当验证者的数字签名,并通过网络传播。 2. 密码排序。虽然速度非常快,但 BA⋆ 协议将受益于进一步的 数百万用户播放时的速度。因此,Algorand 选择 BA⋆ 的球员为所有用户集合的一个小得多的子集。避免不同类型的权力集中 问题,每个新区块 Br 将通过新的 BA⋆ 执行来构建并达成一致, 由一组单独选定的验证者,SV r。原则上,选择这样一个集合可能会像 直接选择Br。我们通过一种我们称之为“拥抱”的方法来解决这个潜在的问题 莫里斯 \(\cdot\) 赫利希(Maurice Herlihy)富有洞察力的建议,密码抽签。排序的做法是 从大量符合条件的个人中随机选择官员[6]。 (进行了排序 跨越几个世纪:例如,雅典、佛罗伦萨和威尼斯共和国。在现代司法中 系统中,通常采用随机选择来选择陪审团。最近还进行了随机抽样 David Chaum [9] 提倡选举。)当然,在去中心化系统中,选择 随机选择每个验证者集合 SV r 的成员所需的随机硬币是有问题的。 因此,我们求助于密码学,以便从所有用户群体中选择每个验证者集, 以保证自动(即不需要消息交换)和随机的方式。 本质上,我们使用密码学函数来自动确定,从前一个块 Br−1,用户,领导者,负责提议新区块 Br,验证者集合 SV r,在 负责就领导者提出的区块达成一致。由于恶意用户可能会影响 Br−1 的组成(例如,通过选择它的一些付款),我们专门构建和使用 额外的输入,以证明第 r 个区块的领导者和验证者集 SV r 确实是 随机选择的。 3. 数量(种子) Qr.我们使用 blockchain 中的最后一个块 Br−1 自动确定下一个验证者集和负责构建新区块的领导者 Br。这种方法的挑战在于,只需在支付方式中选择略有不同的支付方式 上一轮,我们强大的对手对下一个领导者获得了巨大的控制权。即使他 只控制系统中1/1000的玩家/金钱,他可以保证所有的领导者 恶意的。 (参见直觉第 4.1 节。)这一挑战是所有 proof-of-stake 方法的核心, 据我们所知,到目前为止,这个问题还没有得到令人满意的解决。 为了应对这一挑战,我们有目的地构建并不断更新一个单独的、仔细的 定义的数量 Qr,可以证明,它不仅是不可预测的,而且也是不可影响的,由我们 强大的对手。我们可以将 Qr 称为第 r 个种子,因为 Algorand 从 Qr 中选择, 通过秘密密码抽签,所有在生成中扮演特殊角色的用户 第 r 个块。 4. 秘密密码分类和秘密凭证。随机且明确地使用当前最后一个区块 Br−1,以选择验证者集和负责的领导者 仅仅构建新区块 Br 还不够。由于在生成 Br 之前必须知道 Br−1, Br−1 中包含的最后一个不受影响的量 Qr−1 也必须已知。据此,所以 是负责计算区块 Br 的验证者和领导者。因此,我们强大的对手 在他们参与任何有关 Br 的讨论之前,可能会立即腐蚀他们所有人,以便获得 完全控制他们认证的区块。 为了防止这个问题,领导者(实际上也是验证者)秘密地了解他们的角色,但可以 计算一个适当的凭证,能够向每个人证明确实具有该角色。当 用户私下意识到他是下一个区块的领导者,首先他秘密地组装他的 自己提议的新区块,然后将其与他自己的区块一起传播(以便可以被认证) 凭证。这样,虽然对手会立即意识到谁是下一个领导者 阻止是,尽管他可以立即腐蚀他,但对手要阻止他就为时已晚了。 影响新区块的选择。确实,他不能再“回拨”领导的消息了强大的政府无法将维基解密病毒式传播的信息放回瓶子里。 正如我们将看到的,我们不能保证领导者的唯一性,也不能保证每个人都确定谁是领导者 就是,包括领导本人!但是,在 Algorand 中,将保证取得明确的进展。 5. 球员可替换性。在他提出一个新的区块后,领导者可能会“死”(或者被 被对手腐蚀了),因为他的工作已经完成了。但是,对于 SV r 中的验证者来说,事情就少了 简单。事实上,负责用足够多的签名来验证新区块 Br, 他们必须首先在领导者提议的区块上运行拜占庭协议。问题是, 无论效率如何,BA⋆需要多个步骤以及> 2/3的玩家的诚实。 这是一个问题,因为出于效率原因,BA⋆的参与者集由小集SV r组成 从所有用户集中随机选择。因此,我们强大的对手虽然无法 腐败了所有用户的1/3,当然可以腐败SV r的所有成员! 幸运的是,我们将证明通过以点对点方式传播消息来执行的协议 BA⋆ 是玩家可替换的。这一新颖的要求意味着协议正确且 即使每个步骤都是由全新的、随机的执行,也能有效地达成共识 以及独立挑选的球员。因此,对于数百万用户来说,每一小部分玩家 与 BA 的一个步骤相关联,很可能与下一组有空的交集。 另外,BA⋆不同阶段的玩家集合可能会有完全不同的 基数。此外,每组的成员都不知道下一组的玩家是谁 是,并且不秘密传递任何内部状态。 可替换球员的属性实际上对于击败动态且非常强大的球员至关重要 我们设想的对手。我们相信可替换球员协议将在许多方面发挥至关重要的作用 上下文和应用程序。特别是,它们对于安全执行小型子协议至关重要 嵌入到一个更大的玩家世界中,对手是一个充满活力的对手,他们甚至能够腐败 玩家总数中的一小部分,不难腐蚀较小范围内的所有玩家 子协议。 附加属性/技术:懒惰的诚实 诚实的用户遵循他的规定 说明,其中包括在线和运行协议。因为 Algorand 仅具有适度的 计算和通信要求,在线并运行协议“ 背景”并不是重大牺牲。当然,诚实的玩家中也有一些“缺席”,比如 由于突然失去连接或需要重新启动,会被自动容忍(因为 我们总是可以认为这样的少数玩家暂时是恶意的)。然而,我们要指出的是, Algorand 可以简单地进行调整,以便在新模型中工作,在该模型中诚实的用户 大部分时间都在离线状态。我们的新模型可以非正式地介绍如下。 懒惰的诚实。粗略地说,用户 i 是懒惰但诚实的,如果 (1) 他遵循他的所有规定 当他被要求参加协议时的指示,并且 (2) 他被要求参加 很少会遵守该协议,并且会提前发出适当的通知。 有了如此宽松的诚实观念,我们可能会更加确信诚实的人会 当我们需要它们时就在手边,并且 Algorand 保证,在这种情况下, 即使在给定时间点,系统也可以安全运行 大多数参与的玩家都是恶意的。1.3 密切相关的工作 工作量证明方法(如引用的 [29] 和 [4])与我们的方法非常正交。也是如此 基于消息传递拜占庭协议或实用拜占庭容错的方法 (如引用的 [8])。事实上,这些协议不能在所有用户组中运行,也不能, 在我们的模型中,仅限于一小部分用户。事实上,我们的强大对手是我的 立即破坏一小部分负责实际运行 BA 协议的所有用户。 我们的方法可以被认为与权益证明 [2] 有关,从某种意义上说,用户的“权力” 区块建设中的资金与他们在系统中拥有的资金成正比(而不是——比如说—— 他们存入“托管”的资金)。 最接近我们的论文是 Pass 和 Shi [30] 的 Sleepy Consensus Model。为了避免 proof-of-work 方法需要大量计算,他们的论文依赖于(并且友善地 学分)Algorand 的秘密密码抽签。有了这个关键的共同点,几个 我们的论文之间存在显着差异。特别是, (1) 它们的设置仅被允许。相比之下,Algorand 也是一个无需许可的系统。 (2) 他们使用中本风格的协议,因此他们的 blockchain 经常分叉。虽然 放弃 proof-of-work,在他们的协议中,要求秘密选出的领导人延长 最长有效(更丰富的意义上)blockchain。因此,分叉是不可避免的,人们必须等待 该区块在链中足够“深入”。 事实上,与对手一起实现他们的目标 能够自适应损坏,它们需要一个深度为 Poly(N) 的块,其中 N 代表 系统中的用户总数。请注意,即使假设可以生成一个块 一分钟内,如果有 N = 1M 用户,则需要等待大约 2M 年 一个区块变成 N 2 深,大约需要 2 年时间才能让一个区块变成 N 深。相比之下, Algorand 的 blockchain 分叉的概率可以忽略不计,即使对手腐败 用户可以立即自适应地使用它的新块,并且可以立即依赖它。 (3) 他们不处理单独的拜占庭协议。 从某种意义上说,他们只是保证 “最终就一系列不断增长的价值观达成共识”。他们的协议是状态复制协议,而不是 比 BA 更重要,并且不能用于就个人利益价值达成拜占庭协议。 相比之下,如果需要的话,Algorand 也只能使用一次,以使数百万用户能够快速 就特定的利息价值达成拜占庭协议。 (4) 它们需要弱同步时钟。也就是说,所有用户的时钟都偏移了一个小时间 δ。相比之下,在 Algorand 中,时钟只需要(本质上)具有相同的“速度”。 (5) 他们的协议适用于懒惰但诚实的用户或诚实的大多数在线用户。 他们善意地赞扬 Algorand 提出了诚实用户集体下线的问题,并感谢 对此提出了懒惰诚实模型。他们的协议不仅适用于懒惰的人 诚实模型,但也在他们的对抗性昏昏欲睡模型中,对手选择哪些用户 哪些是在线的,哪些是离线的,前提是大多数在线用户在任何时候都是诚实的。2 2他们论文的原始版本实际上只考虑了对抗性昏昏欲睡模型中的安全性。 的 Algorand 的原始版本(先于他们的版本)也明确设想假设给定的大多数 在线玩家总是诚实的,但明确地将其排除在考虑范围之外,转而支持懒惰的诚实模型。 (例如,如果在某个时间点,一半的诚实用户选择下线,那么大多数用户 网上的内容很可能是恶意的。因此,为了防止这种情况发生,对手应该强迫他的大部分 腐败的玩家也会下线,这显然违背了他自己的利益。)请注意,一个拥有多数票的协议 如果大多数在线用户总是恶意的,那么懒惰但诚实的玩家就可以正常工作。之所以如此,是因为 足够数量的诚实玩家知道自己在某个罕见的时间点将发挥至关重要的作用,因此会选择 在那些时刻不要离线,也不能被对手强迫离线,因为他不知道谁是 诚实的玩家可能是至关重要的。(6) 他们需要简单诚实的多数。相比之下,当前版本的 Algorand 需要 2/3 诚实的多数。 我们身边的另一篇论文是 Ouroboros:一种可证明安全的权益证明区块链协议, 作者:Kiayias、Russell、David 和 Oliynykov [20]。他们的系统也出现在我们的系统之后。它还 使用密码抽签以可证明的方式免除工作量证明。然而,他们的 系统又是一种中本风格的协议,其中分叉是不可避免且频繁的。 (然而,在他们的模型中,区块不需要像昏昏欲睡的共识模型那么深。) 而且, 他们的系统依赖于以下假设:用作者自己的话说,“(1) 网络高度同步,(2)大多数选定的利益相关者都可以根据需要使用 参与每个时代,(3)利益相关者不会长时间离线, (4) 损坏的自适应性会受到一个小的延迟的影响,该延迟以轮数为线性单位进行测量 安全参数。”相比之下,Algorand 极有可能是无分叉的,并且 不依赖这 4 个假设中的任何一个。特别是,在 Algorand 中,对手能够 瞬间腐蚀他想要控制的用户。
Preliminaries
Preliminaries
2.1 Cryptographic Primitives Ideal Hashing. We shall rely on an efficiently computable cryptographic hash function, H, that maps arbitrarily long strings to binary strings of fixed length. Following a long tradition, we model H as a random oracle, essentially a function mapping each possible string s to a randomly and independently selected (and then fixed) binary string, H(s), of the chosen length. In this paper, H has 256-bit long outputs. Indeed, such length is short enough to make the system efficient and long enough to make the system secure. For instance, we want H to be collisionresilient. That is, it should be hard to find two different strings x and y such that H(x) = H(y). When H is a random oracle with 256-bit long outputs, finding any such pair of strings is indeed difficult. (Trying at random, and relying on the birthday paradox, would require \(2^{256/2} = 2^{128}\) trials.) Digital Signing. Digital signatures allow users to to authenticate information to each other without sharing any sharing any secret keys. A digital signature scheme consists of three fast algorithms: a probabilistic key generator G, a signing algorithm S, and a verification algorithm V . Given a security parameter k, a sufficiently high integer, a user i uses G to produce a pair of k-bit keys (i.e., strings): a “public” key pki and a matching “secret” signing key ski. Crucially, a public key does not “betray” its corresponding secret key. That is, even given knowledge of pki, no one other than i is able to compute ski in less than astronomical time. User i uses ski to digitally sign messages. For each possible message (binary string) m, i first hashes m and then runs algorithm S on inputs H(m) and ski so as to produce the k-bit string \(\text{sig}_{pk_i}(m) \triangleq S(H(m), sk_i)\).³ 3Since H is collision-resilient it is practically impossible that, by signing m one “accidentally signs” a different message m′.
The binary string sigpki(m) is referred to as i’s digital signature of m (relative to pki), and can be more simply denoted by sigi(m), when the public key pki is clear from context. Everyone knowing pki can use it to verify the digital signatures produced by i. Specifically, on inputs (a) the public key pki of a player i, (b) a message m, and (c) a string s, that is, i’s alleged digital signature of the message m, the verification algorithm V outputs either YES or NO. The properties we require from a digital signature scheme are: 1. Legitimate signatures are always verified: If s = sigi(m), then V (pki, m, s) = Y ES; and 2. Digital signatures are hard to forge: Without knowledge of ski the time to find a string s such that V (pki, m, s) = Y ES, for a message m never signed by i, is astronomically long. (Following the strong security requirement of Goldwasser, Micali, and Rivest [17], this is true even if one can obtain the signature of any other message.) Accordingly, to prevent anyone else from signing messages on his behalf, a player i must keep his signing key ski secret (hence the term “secret key”), and to enable anyone to verify the messages he does sign, i has an interest in publicizing his key pki (hence the term “public key”). In general, a message m is not retrievable from its signature sigi(m). In order to virtually deal with digital signatures that satisfy the conceptually convenient “retrievability” property (i.e., to guarantee that the signer and the message are easily computable from a signature, we define \[\text{SIG}_{pk_i}(m) = (i, m, \text{sig}_{pk_i}(m))\] and \[\text{SIG}_i(m) = (i, m, \text{sig}_i(m)), \text{ if } pk_i \text{ is clear.}\] Unique Digital Signing. We also consider digital signature schemes (G, S, V ) satisfying the following additional property. 3. Uniqueness. It is hard to find strings pk′, m, s, and s′ such that \(s \neq s'\) and \(V(pk', m, s) = V(pk', m, s') = 1\). (Note that the uniqueness property holds also for strings pk′ that are not legitimately generated public keys. In particular, however, the uniqueness property implies that, if one used the specified key generator G to compute a public key pk together with a matching secret key sk, and thus knew sk, it would be essentially impossible also for him to find two different digital signatures of a same message relative to pk.) Remarks • From Unique signatures to verifiable random functions. Relative to a digital signature scheme with the uniqueness property, the mapping \(m \rightarrow H(\text{sig}_i(m))\) associates to each possible string m, a unique, randomly selected, 256-bit string, and the correctness of this mapping can be proved given the signature sigi(m). That is, ideal hashing and digital signature scheme satisfying the uniqueness property essentially provide an elementary implementation of a verifiable random function, as introduced and by Micali, Rabin, and Vadhan [27]. (Their original implementation was necessarily more complex, since they did not rely on ideal hashing.)
• Three different needs for digital signatures. In Algorand, a user i relies on digital signatures for (1) Authenticating i’s own payments. In this application, keys can be “long-term” (i.e., used to sign many messages over a long period of time) and come from a ordinary signature scheme. (2) Generating credentials proving that i is entitled to act at some step s of a round r. Here, keys can be long-term, but must come from a scheme satisfying the uniqueness property. (3) Authenticating the message i sends in each step in which he acts. Here, keys must be ephemeral (i.e., destroyed after their first use), but can come from an ordinary signature scheme. • A small-cost simplification. For simplicity, we envision each user i to have a single longterm key. Accordingly, such a key must come from a signature scheme with the uniqueness property. Such simplicity has a small computational cost. Typically, in fact, unique digital signatures are slightly more expensive to produce and verify than ordinary signatures. 2.2 The Idealized Public Ledger Algorand tries to mimic the following payment system, based on an idealized public ledger. 1. The Initial Status. Money is associated with individual public keys (privately generated and owned by users). Letting pk1, . . . , pkj be the initial public keys and a1, . . . , aj their respective initial amounts of money units, then the initial status is \[S^0 = (pk_1, a_1), \ldots, (pk_j, a_j),\] which is assumed to be common knowledge in the system. 2. Payments. Let \(pk\) be a public key currently having \(a \geq 0\) money units, \(pk'\) another public key, and \(a'\) a non-negative number no greater than \(a\). Then, a (valid) payment \(\wp\) is a digital signature, relative to pk, specifying the transfer of a′ monetary units from pk to pk′, together with some additional information. In symbols, \[\wp = \text{SIG}_{pk}(pk, pk', a', I, H(I)),\] where I represents any additional information deemed useful but not sensitive (e.g., time information and a payment identifier), and I any additional information deemed sensitive (e.g., the reason for the payment, possibly the identities of the owners of pk and the pk′, and so on). We refer to pk (or its owner) as the payer, to each pk′ (or its owner) as a payee, and to a′ as the amount of the payment ℘. Free Joining Via Payments. Note that users may join the system whenever they want by generating their own public/secret key pairs. Accordingly, the public key pk′ that appears in the payment ℘above may be a newly generated public key that had never “owned” any money before. 3. The Magic Ledger. In the Idealized System, all payments are valid and appear in a tamper-proof list L of sets of payments “posted on the sky” for everyone to see: \[L = PAY^1, PAY^2, \ldots\]
Each block PAY r+1 consists of the set of all payments made since the appearance of block PAY r. In the ideal system, a new block appears after a fixed (or finite) amount of time. Discussion. • More General Payments and Unspent Transaction Output. More generally, if a public key pk owns an amount a, then a valid payment ℘of pk may transfer the amounts a′ 1, a′ 2, . . ., respectively to the keys pk′ 1, pk′ 2, . . ., so long as P j a′ \(j \leq a\). In Bitcoin and similar systems, the money owned by a public key pk is segregated into separate amounts, and a payment ℘made by pk must transfer such a segregated amount a in its entirety. If pk wishes to transfer only a fraction a′ < a of a to another key, then it must also transfer the balance, the unspent transaction output, to another key, possibly pk itself. Algorand also works with keys having segregated amounts. However, in order to focus on the novel aspects of Algorand, it is conceptually simpler to stick to our simpler forms of payments and keys having a single amount associated to them. • Current Status. The Idealized Scheme does not directly provide information about the current status of the system (i.e., about how many money units each public key has). This information is deducible from the Magic Ledger. In the ideal system, an active user continually stores and updates the latest status information, or he would otherwise have to reconstruct it, either from scratch, or from the last time he computed it. (In the next version of this paper, we shall augment Algorand so as to enable its users to reconstruct the current status in an efficient manner.) • Security and “Privacy”. Digital signatures guarantee that no one can forge a payment by another user. In a payment ℘, the public keys and the amount are not hidden, but the sensitive information I is. Indeed, only H(I) appears in ℘, and since H is an ideal hash function, H(I) is a random 256-bit value, and thus there is no way to figure out what I was better than by simply guessing it. Yet, to prove what I was (e.g., to prove the reason for the payment) the payer may just reveal I. The correctness of the revealed I can be verified by computing H(I) and comparing the resulting value with the last item of ℘. In fact, since H is collision resilient, it is hard to find a second value I′ such that H(I) = H(I′). 2.3 Basic Notions and Notations Keys, Users, and Owners Unless otherwise specified, each public key (“key” for short) is longterm and relative to a digital signature scheme with the uniqueness property. A public key i joins the system when another public key j already in the system makes a payment to i. For color, we personify keys. We refer to a key i as a “he”, say that i is honest, that i sends and receives messages, etc. User is a synonym for key. When we want to distinguish a key from the person to whom it belongs, we respectively use the term “digital key” and “owner”. Permissionless and Permissioned Systems. A system is permissionless, if a digital key is free to join at any time and an owner can own multiple digital keys; and its permissioned, otherwise.
Unique Representation Each object in Algorand has a unique representation. In particular, each set \(\{(x, y, z, \ldots) : x \in X, y \in Y, z \in Z, \ldots\}\) is ordered in a pre-specified manner: e.g., first lexicographically in x, then in y, etc. Same-Speed Clocks There is no global clock: rather, each user has his own clock. User clocks need not be synchronized in any way. We assume, however, that they all have the same speed. For instance, when it is 12pm according to the clock of a user i, it may be 2:30pm according to the clock of another user j, but when it will be 12:01 according to i’s clock, it will 2:31 according to j’s clock. That is, “one minute is the same (sufficiently, essentially the same) for every user”. Rounds Algorand is organized in logical units, r = 0, 1, . . ., called rounds. We consistently use superscripts to indicate rounds. To indicate that a non-numerical quantity Q (e.g., a string, a public key, a set, a digital signature, etc.) refers to a round r, we simply write Qr. Only when Q is a genuine number (as opposed to a binary string interpretable as a number), do we write Q(r), so that the symbol r could not be interpreted as the exponent of Q. At (the start of a) round r > 0, the set of all public keys is PKr, and the system status is Sr = n i, a(r) i , . . . : \(i \in PK^{r_o}\) , where a(r) i is the amount of money available to the public key i. Note that PKr is deducible from Sr, and that Sr may also specify other components for each public key i. For round 0, PK0 is the set of initial public keys, and S0 is the initial status. Both PK0 and S0 are assumed to be common knowledge in the system. For simplicity, at the start of round r, so are PK1, . . . , PKr and S1, . . . , Sr. In a round r, the system status transitions from Sr to Sr+1: symbolically, \[\text{Round } r: S^r \longrightarrow S^{r+1}.\] Payments In Algorand, the users continually make payments (and disseminate them in the way described in subsection 2.7). A payment \(\wp\) of a user \(i \in PK^r\) has the same format and semantics as in the Ideal System. Namely, ℘= SIGi(i, i′, a, I, H(I)) . Payment ℘is individually valid at a round r (is a round-r payment, for short) if (1) its amount a is less than or equal to a(r) i , and (2) it does not appear in any official payset PAY r′ for r′ < r. (As explained below, the second condition means that ℘has not already become effective. A set of round-r payments of i is collectively valid if the sum of their amounts is at most a(r) i . Paysets A round-r payset P is a set of round-r payments such that, for each user i, the payments of i in P (possibly none) are collectively valid. The set of all round-r paysets is PAY(r). A round-r payset P is maximal if no superset of P is a round-r payset. We actually suggest that a payment \(\wp\) also specifies a round \(\rho\), \(\wp = \text{SIG}_i(\rho, i, i', a, I, H(I))\), and cannot be valid at any round outside \([\rho, \rho + k]\), for some fixed non-negative integer \(k\).4 4This simplifies checking whether ℘has become “effective” (i.e., it simplifies determining whether some payset \(PAY^r\) contains \(\wp\). When \(k = 0\), if \(\wp = \text{SIG}_i(r, i, i', a, I, H(I))\), and \(\wp \notin PAY^r\), then \(i\) must re-submit \(\wp\).
Official Paysets For every round r, Algorand publicly selects (in a manner described later on) a single (possibly empty) payset, PAY r, the round’s official payset. (Essentially, PAY r represents the round-r payments that have “actually” happened.) As in the Ideal System (and Bitcoin), (1) the only way for a new user j to enter the system is to be the recipient of a payment belonging to the official payset PAY r of a given round r; and (2) PAY r determines the status of the next round, Sr+1, from that of the current round, Sr. Symbolically, \(PAY^r: S^r \longrightarrow S^{r+1}\). Specifically, 1. the set of public keys of round r + 1, PKr+1, consists of the union of PKr and the set of all payee keys that appear, for the first time, in the payments of PAY r; and 2. the amount of money a(r+1) i that a user i owns in round r + 1 is the sum of ai(r) —i.e., the amount of money \(i\) owned in the previous round (0 if \(i \notin PK^r\))— and the sum of amounts paid to i according to the payments of PAY r. In sum, as in the Ideal System, each status Sr+1 is deducible from the previous payment history: PAY 0, . . . , PAY r. 2.4 Blocks and Proven Blocks In Algorand0, the block Br corresponding to a round r specifies: r itself; the set of payments of round r, PAY r; a quantity Qr, to be explained, and the hash of the previous block, H(Br−1). Thus, starting from some fixed block B0, we have a traditional blockchain: B1 = (1, PAY 1, Q0, H(B0)), B2 = (2, PAY 2, Q1, H(B1)), B3 = (3, PAY 3, Q2, H(B2)), . . . In Algorand, the authenticity of a block is actually vouched by a separate piece of information, a “block certificate” CERT r, which turns Br into a proven block, Br. The Magic Ledger, therefore, is implemented by the sequence of the proven blocks, B1, B2, . . . Discussion As we shall see, CERT r consists of a set of digital signatures for H(Br), those of a majority of the members of SV r, together with a proof that each of those members indeed belongs to SV r. We could, of course, include the certificates CERT r in the blocks themselves, but find it conceptually cleaner to keep it separate.) In Bitcoin each block must satisfy a special property, that is, must “contain a solution of a crypto puzzle”, which makes block generation computationally intensive and forks both inevitable and not rare. By contrast, Algorand’s blockchain has two main advantages: it is generated with minimal computation, and it will not fork with overwhelmingly high probability. Each block Bi is safely final as soon as it enters the blockchain.
2.5 Acceptable Failure Probability To analyze the security of Algorand we specify the probability, F, with which we are willing to accept that something goes wrong (e.g., that a verifier set SV r does not have an honest majority). As in the case of the output length of the cryptographic hash function H, also F is a parameter. But, as in that case, we find it useful to set F to a concrete value, so as to get a more intuitive grasp of the fact that it is indeed possible, in Algorand, to enjoy simultaneously sufficient security and sufficient efficiency. To emphasize that F is parameter that can be set as desired, in the first and second embodiments we respectively set F = 10−12 and F = 10−18 . Discussion Note that 10−12 is actually less than one in a trillion, and we believe that such a choice of F is adequate in our application. Let us emphasize that 10−12 is not the probability with which the Adversary can forge the payments of an honest user. All payments are digitally signed, and thus, if the proper digital signatures are used, the probability of forging a payment is far lower than 10−12, and is, in fact, essentially 0. The bad event that we are willing to tolerate with probability F is that Algorand’s blockchain forks. Notice that, with our setting of F and one-minute long rounds, a fork is expected to occur in Algorand’s blockchain as infrequently as (roughly) once in 1.9 million years. By contrast, in Bitcoin, a forks occurs quite often. A more demanding person may set F to a lower value. To this end, in our second embodiment we consider setting F to 10−18. Note that, assuming that a block is generated every second, 1018 is the estimated number of seconds taken by the Universe so far: from the Big Bang to present time. Thus, with F = 10−18, if a block is generated in a second, one should expect for the age of the Universe to see a fork. 2.6 The Adversarial Model Algorand is designed to be secure in a very adversarial model. Let us explain. Honest and Malicious Users A user is honest if he follows all his protocol instructions, and is perfectly capable of sending and receiving messages. A user is malicious (i.e., Byzantine, in the parlance of distributed computing) if he can deviate arbitrarily from his prescribed instructions. The Adversary The Adversary is an efficient (technically polynomial-time) algorithm, personified for color, who can immediately make malicious any user he wants, at any time he wants (subject only to an upperbound to the number of the users he can corrupt). The Adversary totally controls and perfectly coordinates all malicious users. He takes all actions on their behalf, including receiving and sending all their messages, and can let them deviate from their prescribed instructions in arbitrary ways. Or he can simply isolate a corrupted user sending and receiving messages. Let us clarify that no one else automatically learns that a user i is malicious, although i’s maliciousness may transpire by the actions the Adversary has him take. This powerful adversary however, • Does not have unbounded computational power and cannot successfully forge the digital signature of an honest user, except with negligible probability; and
• Cannot interfere in any way with the messages exchanges among honest users. Furthermore, his ability to attack honest users is bounded by one of the following assumption. Honesty Majority of Money We consider a continuum of Honest Majority of Money (HMM) assumptions: namely, for each non-negative integer k and real h > 1/2, HHMk > h: the honest users in every round r owned a fraction greater than h of all money in the system at round r −k. Discussion. Assuming that all malicious users perfectly coordinate their actions (as if controlled by a single entity, the Adversary) is a rather pessimistic hypothesis. Perfect coordination among too many individuals is difficult to achieve. Perhaps coordination only occurs within separate groups of malicious players. But, since one cannot be sure about the level of coordination malicious users may enjoy, we’d better be safe than sorry. Assuming that the Adversary can secretly, dynamically, and immediately corrupt users is also pessimistic. After all, realistically, taking full control of a user’s operations should take some time. The assumption HMMk > h implies, for instance, that, if a round (on average) is implemented in one minute, then, the majority of the money at a given round will remain in honest hands for at least two hours, if k = 120, and at least one week, if k = 10, 000. Note that the HMM assumptions and the previous Honest Majority of Computing Power assumptions are related in the sense that, since computing power can be bought with money, if malicious users own most of the money, then they can obtain most of the computing power. 2.7 The Communication Model We envisage message propagation —i.e., “peer-to-peer gossip”5— to be the only means of communication. Temporary Assumption: Timely Delivery of Messages in the Entire Network. For most part of this paper we assume that every propagated message reaches almost all honest users in a timely fashion. We shall remove this assumption in Section 10, where we deal with network partitions, either naturally occurring or adversarially induced. (As we shall see, we only assume timely delivery of messages within each connected component of the network.) One concrete way to capture timely delivery of propagated messages (in the entire network) is the following: For all reachability \(\rho > 95\%\) and message size \(\mu \in \mathbb{Z}^+\), there exists \(\lambda_{\rho,\mu}\) such that, if a honest user propagates \(\mu\)-byte message \(m\) at time \(t\), then \(m\) reaches, by time \(t + \lambda_{\rho,\mu}\), at least a fraction \(\rho\) of the honest users. 5Essentially, as in Bitcoin, when a user propagates a message m, every active user i receiving m for the first time, randomly and independently selects a suitably small number of active users, his “neighbors”, to whom he forwards m, possibly until he receives an acknowledgement from them. The propagation of m terminates when no user receives m for the first time.
The above property, however, cannot support our Algorand protocol, without explicitly and separately envisaging a mechanism to obtain the latest blockchain —by another user/depository/etc. In fact, to construct a new block Br not only should a proper set of verifiers timely receive round-r messages, but also the messages of previous rounds, so as to know Br−1 and all other previous blocks, which is necessary to determine whether the payments in Br are valid. The following assumption instead suffices. Message Propagation (MP) Assumption: For all \(\rho > 95\%\) and \(\mu \in \mathbb{Z}^+\), there exists \(\lambda_{\rho,\mu}\) such that, for all times \(t\) and all \(\mu\)-byte messages \(m\) propagated by an honest user before \(t - \lambda_{\rho,\mu}\), \(m\) is received, by time \(t\), by at least a fraction \(\rho\) of the honest users. Protocol Algorand ′ actually instructs each of a small number of users (i.e., the verifiers of a given step of a round in Algorand ′, to propagate a separate message of a (small) prescribed size, and we need to bound the time required to fulfill these instructions. We do so by enriching the MP assumption as follows. For all \(n\), \(\rho > 95\%\), and \(\mu \in \mathbb{Z}^+\), there exists \(\lambda_{n,\rho,\mu}\) such that, for all times \(t\) and all \(\mu\)-byte messages \(m_1, \ldots, m_n\), each propagated by an honest user before \(t - \lambda_{n,\rho,\mu}\), \(m_1, \ldots, m_n\) are received, by time \(t\), by at least a fraction \(\rho\) of the honest users. Note • The above assumption is deliberately simple, but also stronger than needed in our paper.6 • For simplicity, we assume \(\rho = 1\), and thus drop mentioning \(\rho\). • We pessimistically assume that, provided he does not violate the MP assumption, the Adversary totally controls the delivery of all messages. In particular, without being noticed by the honest users, the Adversary he can arbitrarily decide which honest player receives which message when, and arbitrarily accelerate the delivery of any message he wants.7
预备知识
2.1 密码原语 理想的哈希。 我们将依赖于一个高效可计算的密码 hash 函数 H, 将任意长的字符串映射为固定长度的二进制字符串。遵循悠久的传统,我们建模 H 作为一个随机 oracle,本质上是一个将每个可能的字符串 s 映射到随机和 独立选择(然后固定)所选长度的二进制字符串 H(s)。 在本文中,H 具有 256 位长输出。事实上,这样的长度足够短,可以使 系统高效且足够长以确保系统安全。例如,我们希望 H 具有碰撞弹性。也就是说,应该很难找到两个不同的字符串 x 和 y 使得 H(x) = H(y)。 当 H 是具有 256 位长输出的随机 oracle 时,找到任何这样的字符串对确实是 困难。 (随机尝试并依赖生日悖论,需要 2256/2 = 2128 试验。) 数字签名。 数字签名允许用户相互验证信息 无需共享任何共享密钥。 数字签名方案由三个快速 算法:概率密钥生成器 G、签名算法 S 和验证算法 V。 给定一个安全参数 k(一个足够大的整数),用户 i 使用 G 生成一对 k 位密钥(即字符串):“公共”密钥 pki 和匹配的“秘密”签名密钥 ski。至关重要的是,一个 公钥不会“背叛”其相应的秘密密钥。也就是说,即使了解 pki,也不能 除了我之外,还有人能够在不到天文时间的时间内计算出滑雪。 用户 i 使用ski 对消息进行数字签名。对于每个可能的消息(二进制字符串)m, i 首先 hashes m,然后对输入 H(m) 和 ski 运行算法 S,以生成 k 位字符串 sigpki(m) \(\triangleq\)S(H(m), 滑雪) .3 3 由于 H 具有抗碰撞能力,因此实际上不可能通过签署 m 来“意外地签署”不同的 消息 m′。二进制串 sigpki(m) 被称为 i 对 m 的数字签名(相对于 pki),可以表示为 当公钥 pki 从上下文中清晰可见时,更简单地表示为 sigi(m)。 每个知道 pki 的人都可以用它来验证 i 生成的数字签名。具体来说,关于 输入 (a) 玩家 i 的公钥 pki,(b) 消息 m,以及 (c) 字符串 s,即 i 被称为 消息 m 的数字签名,验证算法 V 输出 YES 或 NO。 我们要求数字签名方案具有以下属性: 1. 合法签名总是经过验证的:如果 s = sigi(m),则 V (pki, m, s) = Y ES;和 2. 数字签名很难伪造:在不了解滑雪知识的情况下,找到这样的字符串的时间 对于从未由 i 签名的消息 m,V (pki, m, s) = Y ES 的长度是天文数字。 (遵循 Goldwasser、Micali 和 Rivest [17] 的强大安全要求,这是事实 即使可以获得任何其他消息的签名。) 因此,为了防止其他人代表他签署消息,玩家必须保留他的 签署密钥滑雪秘密(因此称为“秘密密钥”),并使任何人都可以验证消息 他确实签名了,我有兴趣公开他的密钥 pki(因此称为“公钥”)。 一般来说,消息 m 无法从其签名 sigi(m) 中检索。为了虚拟地进行交易 具有满足概念上方便的“可检索性”属性的数字签名(即, 保证签名者和消息可以很容易地从签名中计算出来,我们定义 SIGpki(m) = (i, m, sigpki(m)) 和 SIGi(m) = (i, m, sigi(m)),如果 pki 明确。 独特的数字签名。 我们还考虑满足以下条件的数字签名方案(G,S,V) 以下附加属性。 3.独特性。很难找到满足以下条件的字符串 pk′、m、s 和 s′ s̸=s′ 和 V (pk', m, s) = V (pk', m, s') = 1。 (请注意,唯一性属性也适用于不是合法生成的字符串 pk′ 公钥。 然而,特别是,唯一性属性意味着,如果人们使用 指定密钥生成器 G 来计算公钥 pk 以及匹配的密钥 sk, 因此知道 sk,他基本上也不可能找到两个不同的数字 相同消息相对于 pk 的签名。) 备注 • 从独特的签名到可验证的随机函数。 相对于数字 具有唯一性属性的签名方案,映射 m \(\to\) H(sigi(m)) 关联到 每个可能的字符串 m,一个唯一的、随机选择的 256 位字符串,以及该字符串的正确性 给定签名 sigi(m) 即可证明映射。 即理想的hashing和数字签名方案本质上满足唯一性 提供可验证随机函数的基本实现,如所介绍的和 米卡利、拉宾和瓦丹 [27]。 (他们最初的实现必然更复杂, 因为他们不依赖于理想的 hashing。)• 数字签名的三种不同需求。在 Algorand 中,用户 i 依赖数字 签名为 (1) 验证我自己的付款。在此应用程序中,密钥可以是“长期的”(即,用于 在很长一段时间内对许多消息进行签名)并且来自普通的签名方案。 (2) 生成凭证,证明 i 有权在第 r 轮的某些步骤 s 中采取行动。在这里, 密钥可以是长期的,但必须来自满足唯一性属性的方案。 (3) 验证i在其执行的每个步骤中发送的消息。 这里,键必须是 短暂的(即在第一次使用后被销毁),但可以来自普通的签名方案。 • 小成本的简化。为简单起见,我们设想每个用户 i 都有一个长期密钥。因此,这样的密钥必须来自具有唯一性的签名方案 财产。这种简单性的计算成本很小。事实上,通常独特的数字 签名的生成和验证成本比普通签名稍高。 2.2 理想化的公共账本 Algorand 尝试模仿以下基于理想化公共分类账的支付系统。 1. 初始状态。金钱与个人公钥(私人生成和 归用户所有)。令 pk1, . 。 。 , pkj 是初始公钥,a1, . 。 。 , aj 各自的 初始金额单位,则初始状态为 S0 = (pk1, a1), . 。 。 , (pkj, aj), 假设这是系统中的常识。 2. 付款。设 pk 为当前拥有 \(\geq\)0 货币单位的公钥,pk′ 为另一个公钥 key,a′是不大于a的非负数。那么,(有效)支付 \(\wp\) 是一个数字 签名,相对于pk,指定a′货币单位从pk到pk′的转移,一起 以及一些附加信息。在符号中, \(\wp\)= SIGpk(pk, pk′, a′, I, H(I)), 其中 I 代表任何被认为有用但不敏感的附加信息(例如,时间 信息和付款标识符),以及任何被视为敏感的其他信息(例如, 付款原因,可能是 pk 和 pk' 所有者的身份,等等)。 我们将 pk(或其所有者)称为付款人,将每个 pk'(或其所有者)称为收款人,将 a' 称为收款人 付款金额\(\wp\)。 通过付款免费加入。请注意,用户可以随时通过以下方式加入系统 生成自己的公钥/密钥对。相应地,出现在中的公钥pk' 上面的支付\(\wp\)可能是新生成的公钥,从未“拥有”任何钱 之前。 3.魔法账本。在理想化系统中,所有付款都是有效的,并以防篡改的方式显示 L组付款清单“贴在天上”供大家查看: L = 支付 1,支付 2,. 。 。 ,每个区块 PAY r+1 包含自区块出现以来所有支付的集合 支付 r。在理想的系统中,一个新的块会在固定(或有限)的时间后出现。 讨论。 • 更一般的支付和未花费的交易输出。 更一般地,如果公钥 pk 拥有金额 a,那么 pk 的有效支付 \(\wp\) 可以转移金额 a′ 1、a′ 2、. 。 ., 分别对应键 pk′ 1、pk′ 2、. 。 .,只要P j a′ j\(\leq\)a。 在 Bitcoin 和类似系统中,公钥 pk 拥有的资金被分成单独的 金额,并且 pk 进行的支付 \(\wp\) 必须全部转移这样的隔离金额 a。 如果 pk 希望仅将 a 的一小部分 a′ < a 转移到另一个密钥,那么它还必须将 余额,未使用的交易输出,到另一个密钥,可能是 pk 本身。 Algorand 也适用于具有隔离金额的密钥。然而,为了集中精力 Algorand 的新颖方面,从概念上讲,坚持我们更简单的付款方式更简单 以及具有与其关联的单一金额的密钥。 • 当前状态。理想化方案不直接提供有关当前情况的信息 系统的状态(即每个公钥有多少货币单位)。此信息 可以从魔法账本中推断出来。 在理想的系统中,活跃用户不断存储和更新最新的状态信息, 否则他就必须重建它,要么从头开始,要么从上次他 计算了一下。 (在本文的下一版本中,我们将增强 Algorand 以使其能够 用户以有效的方式重建当前状态。) • 安全和“隐私”。 数字签名保证任何人都无法伪造付款 另一个用户。在支付\(\wp\)中,公钥和金额不是隐藏的,而是敏感的 信息我是。事实上,只有 H(I) 出现在 \(\wp\) 中,并且由于 H 是理想的 hash 函数,因此 H(I) 是一个随机的 256 位值,因此无法找出我比 只是猜测而已。然而,为了证明我是什么(例如,证明付款的原因) 付款人可以直接透露 I。所透露的 I 的正确性可以通过计算 H(I) 来验证 并将结果值与 \(\wp\) 的最后一项进行比较。事实上,由于 H 具有碰撞弹性, 很难找到第二个值 I′ 使得 H(I) = H(I′)。 2.3 基本概念和符号 密钥、用户和所有者 除非另有说明,每个公钥(简称“密钥”)都是长期的,并且与具有唯一性的数字签名方案相关。我加入的公钥 当系统中已有另一个公钥 j 向 i 付款时,系统将执行此操作。 对于颜色,我们将钥匙拟人化。我们将密钥 i 称为“他”,表示我是诚实的,我发送 并接收消息等。 User 是 key 的同义词。当我们想要区分一个键时 对于它所属的人,我们分别使用术语“数字密钥”和“所有者”。 免许可和许可系统。 如果数字密钥是免费的,则系统是无需许可的 随时加入,一个所有者可以拥有多个数字钥匙;并获得许可,否则。独特的表现 Algorand 中的每个对象都有一个唯一的表示。特别是, 每个集合 {(x, y, z, . . .) : x \(\in\)X, y \(\in\)Y, z \(\in\)Z, . 。 .} 以预先指定的方式排序:例如,first 按字典顺序先在 x 中,然后在 y 中,依此类推。 同速时钟 没有全局时钟:相反,每个用户都有自己的时钟。用户时钟 不需要以任何方式同步。然而,我们假设它们都具有相同的速度。 例如,当根据用户i的时钟是中午12点时,根据用户i的时钟,可能是下午2:30 另一个用户j的时钟,但是当根据i的时钟为12:01时,根据i的时钟为2:31 到j的时钟。也就是说,“一分钟对于每个用户来说都是相同的(充分、本质上相同)”。 回合 Algorand 以逻辑单元组织,r = 0, 1, . 。 .,称为回合。 我们一贯使用上标来表示轮次。表示非数字量 Q (例如,字符串、公钥、集合、数字签名等)指的是一轮r,我们简单地写成Qr。 仅当 Q 是一个真正的数字(而不是可解释为数字的二进制字符串)时,才执行 我们写成Q(r),这样符号r就不能被解释为Q的指数。 在(a的开始)r > 0轮时,所有公钥的集合是PKr,系统状态是 锶= n 我,一个(r) 我,. 。 。 : i \(\in\) PKro , 其中a(r) 我 是公钥 i 可用的金额。请注意,PKr 可从 Sr,并且Sr还可以为每个公钥i指定其他组件。 对于第0轮,PK0是初始公钥的集合,S0是初始状态。 PK0 和 S0 被假设为系统中的常识。为简单起见,在 r 轮开始时,所以 是 PK1, . 。 。 ,PKr 和 S1,。 。 。 ,先生。 在r轮中,系统状态从Sr转变为Sr+1:象征性地, r轮:Sr−→Sr+1。 付款方式 在 Algorand 中,用户不断进行付款(并以以下方式传播) 第 2.7 节中描述)。用户 i \(\in\)PKr 的支付 \(\wp\) 具有相同的格式和语义 就像在理想系统中一样。即, \(\wp\)= SIGi(i, i′, a, I, H(I)) 。 付款 \(\wp\) 在第 r 轮中单独有效(简称为第 r 轮付款),如果 (1) 其金额 a 小于或等于 a(r) i ,并且 (2) 它不会出现在任何官方支付集 PAY r′ 中,因为 r′ < r。 (如下所述,第二个条件意味着 \(\wp\) 尚未生效。 如果 i 的一组 r 轮付款的金额之和最多为 a(r),则它们集体有效 我。 支付方式 r 轮支付集 P 是 r 轮支付的集合,使得对于每个用户 i,支付 P 中的 i 个(可能没有)集体有效。所有 r 轮支付集的集合是 PAY(r)。一轮R 如果 P 的超集不是第 r 轮支付集,则支付集 P 是最大的。 我们实际上建议支付 \(\wp\)也指定一轮 \(\rho\), \(\wp\)= SIGi(\(\rho\), i, i′, a, I, H(I)) , 对于某个固定的非负整数 k.4,在 [\(\rho\), \(\rho\) + k] 之外的任何一轮都无效 4这简化了检查\(\wp\)是否已变得“有效”(即,它简化了确定某些支付集是否 PAY r 包含 \(\wp\)。当 k = 0 时,如果 \(\wp\)= SIGi(r, i, i′, a, I, H(I)) 且 \(\wp\)/\(\varepsilon\)PAY r,则 i 必须重新提交 \(\wp\)。官方支付 对于每一轮 r,Algorand 公开选择(以稍后描述的方式) 单个(可能是空的)支付集,PAY r,该轮的官方支付集。 (本质上,PAY r 代表 “实际”发生的 R 轮付款。) 与理想系统(和Bitcoin)一样,(1)新用户j进入系统的唯一途径 是属于给定回合 r 的官方支付集 PAY r 的付款的接收者;和 (2) PAY r 根据本轮的状态 Sr 确定下一轮的状态 Sr+1。 象征性地, 支付 r : Sr −→Sr+1。 具体来说, 1.第r+1轮的公钥集合PKr+1,由PKr和所有的集合的并集组成 首次出现在 PAY r 付款中的收款人密钥;和 2.金额a(r+1) 我 用户 i 在第 r + 1 轮中拥有的资产是 ai(r) 的总和,即 我在上一轮中拥有的金额(如果 i ̸\(\varepsilon\)PKr 则为 0)— 以及金额总和 根据PAY r的付款方式支付给i。 总之,就像在理想系统中一样,每个状态 Sr+1 都可以从之前的付款历史中扣除: 支付0,. 。 。 , 支付 r。 2.4 区块和已验证的区块 在 Algorand0 中,对应于一轮 r 的块 Br 指定: r 本身;的支付集合 r 轮,支付 r;需要解释的数量 Qr 以及前一个块的 hash H(Br−1)。 因此,从某个固定块 B0 开始,我们有一个传统的 blockchain: B1 = (1, 支付 1, Q0, H(B0)), B2 = (2, 支付 2, Q1, H(B1)), B3 = (3, 支付 3, Q2, H(B2)), 。 。 。 在 Algorand 中,块的真实性实际上是由一条单独的信息来保证的, “区块证书”CERT r,它将 Br 变成经过验证的区块 Br。因此,魔法账本 通过已证明的块的顺序来实现, B1、B2、. 。 。 讨论 正如我们将看到的,CERT r 由一组 H(Br) 的数字签名组成, SV r 的大多数成员,以及每个成员确实属于的证明 到 SV r。当然,我们可以将证书 CERT r 包含在块本身中,但是会发现它 概念上更清晰,以将其分开。) 在 Bitcoin 中,每个块必须满足一个特殊属性,即必须“包含 加密难题”,这使得区块生成需要大量计算,并且分叉不可避免 而且并不罕见。相比之下,Algorand 的 blockchain 有两个主要优点:它是用 最小的计算量,并且它不会以极高的概率分叉。每个块Bi是 一旦进入blockchain,就安全地结束。2.5 可接受的故障概率 为了分析 Algorand 的安全性,我们指定概率 F,我们愿意使用该概率 接受出现问题的情况(例如,验证者集 SV r 没有诚实多数)。 与加密 hash 函数 H 的输出长度的情况一样,F 也是一个参数。 但是,在这种情况下,我们发现将 F 设置为一个具体值很有用,以便获得更直观的结果 掌握这样一个事实:在 Algorand 中,确实可以同时享受足够的安全 和足够的效率。为了强调F是可以根据需要设置的参数,在第一个 和第二实施例我们分别设置 F = 10−12 和 F = 10−18 。 讨论 请注意,10−12 实际上小于万亿分之一,我们相信这样的 在我们的应用中选择 F 就足够了。让我们强调 10−12 不是概率 对手可以用它伪造诚实用户的付款。所有付款均以数字方式进行 签名,因此,如果使用正确的数字签名,伪造付款的概率为 远低于 10−12,事实上,本质上是 0。我们愿意容忍的坏事件 概率 F 是 Algorand 的 blockchain 分叉。请注意,我们设置 F 和 在一分钟长的回合中,预计 Algorand 的 blockchain 中出现分叉的频率为 (大约)190 万年一次。相比之下,在 Bitcoin 中,分叉经常发生。 要求较高的人可以将F设置为较低的值。为此,在我们的第二实施例中 我们考虑将 F 设置为 10−18。注意,假设每秒生成一个区块,1018 是迄今为止宇宙所花费的估计秒数:从大爆炸到现在 时间。因此,在 F = 10−18 的情况下,如果一秒内生成一个区块,则应该预期其年龄为 宇宙看到一个叉子。 2.6 对抗模型 Algorand 被设计为在非常对抗的模型中是安全的。让我们解释一下。 诚实用户和恶意用户 如果用户遵循所有协议说明,则他是诚实的,并且 完全有能力发送和接收消息。用户是恶意的(即拜占庭,在 分布式计算的用语)如果他可以任意偏离他规定的指令。 对手 对手是一种高效的(技术上多项式时间)算法,以颜色拟人化,他可以在任何他想要的时间立即对任何他想要的用户进行恶意攻击(主题 仅限于他可以破坏的用户数量的上限)。 对手完全控制并完美协调所有恶意用户。他采取一切行动 代表他们,包括接收和发送他们的所有消息,并可以让他们偏离 他们以任意方式规定的指示。或者他可以简单地隔离发送损坏的用户 并接收消息。让我们澄清一下,没有其他人会自动得知用户 i 是恶意的, 尽管我的恶意可能会通过对手让他采取的行动而显现出来。 然而这个强大的对手, • 不具备无限的计算能力,无法成功伪造数字 诚实用户的签名,除非概率可以忽略不计;和• 不能以任何方式干扰诚实用户之间的消息交换。 此外,他攻击诚实用户的能力受到以下假设之一的限制。 诚信占多数金钱 我们考虑诚实多数货币 (HMM) 的连续体 假设:即对于每个非负整数 k 且实数 h > 1/2, HHMk > h:每轮 r 中的诚实用户拥有的所有资金中的一部分大于 h 系统在 r −k 轮。 讨论。 假设所有恶意用户完美地协调他们的行动(就好像被控制一样) 由单一实体(即对手)造成的)是一个相当悲观的假设。之间也完美协调 很多个人是很难实现的。也许协调只发生在不同的群体中 的恶意玩家。但是,由于无法确定恶意用户的协调程度 可能会享受,我们最好是安全而不是后悔。 假设攻击者也可以秘密地、动态地、立即地破坏用户 悲观的。毕竟,实际上,完全控制用户的操作应该需要一些时间。 例如,假设 HMMk > h 意味着,如果实施一轮(平均) 那么,在一分钟内,某一轮的大部分资金将留在诚实的手中 如果 k = 120,则至少 2 小时;如果 k = 10, 000,则至少 1 周。 请注意,HMM 假设和之前的诚实多数计算能力 假设是相关的,因为计算能力可以用金钱购买, 如果恶意用户拥有大部分资金,那么他们就可以获得大部分算力。 2.7 沟通模式 我们设想消息传播——即“点对点八卦”5——是唯一的手段 沟通。 临时假设:全网消息及时传递。 对于 本文的大部分内容我们假设每条传播的消息都到达了几乎所有诚实的用户 及时。我们将在第 10 节中删除这个假设,在第 10 节中我们处理网络 分区,无论是自然发生的还是敌对引起的。 (正如我们将看到的,我们只假设 在网络的每个连接组件内及时传递消息。) 捕获传播消息(在整个网络中)的及时传递的一种具体方法是 以下: 对于所有可达性 \(\rho\) > 95% 且消息大小 \(\mu\) \(\in\)Z+,存在 \(\lambda\) \(\rho\),\(\mu\) 使得, 如果诚实的用户在时间 t 传播 \(\mu\) 字节消息 m, 那么到时间 t + \(\lambda\) \(\rho\),μ 时,m 至少达到诚实用户的一小部分 \(\rho\)。 5本质上,如Bitcoin中,当用户传播消息m时,每个活跃用户i第一次接收m, 随机且独立地选择适当少量的活跃用户,即他的“邻居”,他将 m 转发给他们, 可能直到他收到他们的确认为止。当没有用户接收时 m 的传播终止 m 第一次。然而,如果没有明确且单独地设想一种由另一个用户/存储库等获取最新的 blockchain 的机制,则上述属性无法支持我们的 Algorand 协议。 事实上,构建一个新的区块 Br 不仅需要一组适当的验证者及时接收轮次 r 消息,还有前几轮的消息,以便知道 Br−1 和所有其他先前的消息 块,这是确定 Br 中的付款是否有效所必需的。 以下 假设就足够了。 消息传播 (MP) 假设: 对于所有 \(\rho\) > 95% 且 \(\mu\) \(\in\)Z+,存在 \(\lambda\) \(\rho\),\(\mu\) 这样,对于所有时间 t 以及诚实用户在 t −\(\lambda\) \(\rho\),μ 之前传播的所有 \(\mu\) 字节消息 m, m 在时间 t 之前被至少一小部分 \(\rho\) 的诚实用户接收。 协议 Algorand ' 实际上指示一小部分用户中的每一个(即,一个 Algorand ' 中一轮的给定步骤,传播(小)规定大小的单独消息, 我们需要限制完成这些指示所需的时间。我们通过充实议员来做到这一点 假设如下。 对于所有 n、\(\rho\) > 95% 且 \(\mu\) \(\in\)Z+,存在 \(\lambda\)n,\(\rho\),\(\mu\),使得对于所有时间 t 和所有 \(\mu\) 字节 消息 m1, . 。 。 , mn,每个都由诚实用户在 t −\(\lambda\)n,\(\rho\),μ, m1,... 之前传播。 。 。 , mn 收到, 到时间 t,至少有一小部分 \(\rho\) 是诚实用户。 注意事项 • 上述假设故意简单,但也比我们论文中所需的更强。6 • 为简单起见,我们假设\(\rho\) = 1,因此不再提及\(\rho\)。 • 我们悲观地假设,只要对手不违反 MP 假设,对手 完全控制所有消息的传递。特别是在不被诚实的人注意到的情况下 用户,对手他可以任意决定哪个诚实的玩家接收哪个消息, 并任意加速传递他想要的任何消息。7
The BA Protocol BA⋆in a Traditional Setting
The BA Protocol BA⋆in a Traditional Setting
As already emphasized, Byzantine agreement is a key ingredient of Algorand. Indeed, it is through the use of such a BA protocol that Algorand is unaffected by forks. However, to be secure against our powerful Adversary, Algorand must rely on a BA protocol that satisfies the new player-replaceability constraint. In addition, for Algorand to be efficient, such a BA protocol must be very efficient. BA protocols were first defined for an idealized communication model, synchronous complete networks (SC networks). Such a model allows for a simpler design and analysis of BA protocols. 6Given the honest percentage h and the acceptable failure probability F, Algorand computes an upperbound, N, to the maximum number of member of verifiers in a step. Thus, the MP assumption need only hold for \(n \leq N\). In addition, as stated, the MP assumption holds no matter how many other messages may be propagated alongside the mj’s. As we shall see, however, in Algorand messages at are propagated in essentially non-overlapping time intervals, during which either a single block is propagated, or at most N verifiers propagate a small (e.g., 200B) message. Thus, we could restate the MP assumption in a weaker, but also more complex, way. 7For instance, he can immediately learn the messages sent by honest players. Thus, a malicious user i′, who is asked to propagate a message simultaneously with a honest user i, can always choose his own message m′ based on the message m actually propagated by i. This ability is related to rushing, in the parlance of distributed-computation literature.
Accordingly, in this section, we introduce a new BA protocol, BA⋆, for SC networks and ignoring the issue of player replaceability altogether. The protocol BA⋆is a contribution of separate value. Indeed, it is the most efficient cryptographic BA protocol for SC networks known so far. To use it within our Algorand protocol, we modify BA⋆a bit, so as to account for our different communication model and context, but make sure, in section X, to highlight how BA⋆is used within our actual protocol Algorand ′. We start by recalling the model in which BA⋆operates and the notion of a Byzantine agreement. 3.1 Synchronous Complete Networks and Matching Adversaries In a SC network, there is a common clock, ticking at each integral times r = 1, 2, . . . At each even time click r, each player i instantaneously and simultaneously sends a single message mr i,j (possibly the empty message) to each player j, including himself. Each mr i,j is received at time click r + 1 by player j, together with the identity of the sender i. Again, in a communication protocol, a player is honest if he follows all his prescribed instructions, and malicious otherwise. All malicious players are totally controlled and perfectly coordinated by the Adversary, who, in particular, immediately receives all messages addressed to malicious players, and chooses the messages they send. The Adversary can immediately make malicious any honest user he wants at any odd time click he wants, subject only to a possible upperbound t to the number of malicious players. That is, the Adversary “cannot interfere with the messages already sent by an honest user i”, which will be delivered as usual. The Adversary also has the additional ability to see instantaneously, at each even round, the messages that the currently honest players send, and instantaneously use this information to choose the messages the malicious players send at the same time tick. Remarks • Adversary Power. The above setting is very adversarial. Indeed, in the Byzantine agreement literature, many settings are less adversarial. However, some more adversarial settings have also been considered, where the Adversary, after seeing the messages sent by an honest player i at a given time click r, has the ability to erase all these messages from the network, immediately corrupt i, choose the message that the now malicious i sends at time click r, and have them delivered as usual. The envisaged power of the Adversary matches that he has in our setting. • Physical Abstraction. The envisaged communication model abstracts a more physical model, in which each pair of players (i, j) is linked by a separate and private communication line li,j. That is, no one else can inject, interfere with, or gain information about the messages sent over li,j. The only way for the Adversary to have access to li,j is to corrupt either i or j. • Privacy and Authentication. In SC networks message privacy and authentication are guaranteed by assumption. By contrast, in our communication network, where messages are propagated from peer to peer, authentication is guaranteed by digital signatures, and privacy is non-existent. Thus, to adopt protocol BA⋆to our setting, each message exchanged should be digitally signed (further identifying the state at which it was sent). Fortunately, the BA protocols that we consider using in Algorand do not require message privacy.
3.2 The Notion of a Byzantine Agreement The notion of Byzantine agreement was introduced by Pease Shostak and Lamport [31] for the binary case, that is, when every initial value consists of a bit. However, it was quickly extended to arbitrary initial values. (See the surveys of Fischer [16] and Chor and Dwork [10].) By a BA protocol, we mean an arbitrary-value one. Definition 3.1. In a synchronous network, let \(P\) be a \(n\)-player protocol, whose player set is common knowledge among the players, \(t\) a positive integer such that \(n \geq 2t + 1\). We say that \(P\) is an arbitrary-value (respectively, binary) \((n, t)\)-Byzantine agreement protocol with soundness \(\sigma \in (0, 1)\) if, for every set of values \(V\) not containing the special symbol \(\bot\) (respectively, for \(V = \{0, 1\}\)), in an execution in which at most \(t\) of the players are malicious and in which every player \(i\) starts with an initial value \(v_i \in V\), every honest player \(j\) halts with probability 1, outputting a value \(\text{out}_i \in V \cup \{\bot\}\) so as to satisfy, with probability at least \(\sigma\), the following two conditions: 1. Agreement: There exists \(\text{out} \in V \cup \{\bot\}\) such that \(\text{out}_i = \text{out}\) for all honest players \(i\). 2. Consistency: if, for some value \(v \in V\), \(v_i = v\) for all honest players, then \(\text{out} = v\). We refer to out as P’s output, and to each outi as player i’s output. 3.3 The BA Notation # In our BA protocols, a player is required to count how many players sent him a given message in a given step. Accordingly, for each possible value \(v\) that might be sent, \(\#_i^s(v)\) (or just \(\#_i(v)\) when \(s\) is clear) is the number of players \(j\) from which \(i\) has received \(v\) in step \(s\). Recalling that a player \(i\) receives exactly one message from each player \(j\), if the number of players is \(n\), then, for all \(i\) and \(s\), \(\sum_v \#_i^s(v) = n\). 3.4 The Binary BA Protocol BBA⋆ In this section we present a new binary BA protocol, BBA⋆, which relies on the honesty of more than two thirds of the players and is very fast: no matter what the malicious players might do, each execution of its main loop brings the players into agreement with probability 1/3. Each player has his own public key of a digital signature scheme satisfying the unique-signature property. Since this protocol is intended to be run on synchronous complete network, there is no need for a player i to sign each of his messages. Digital signatures are used to generate a sufficiently common random bit in Step 3. (In Algorand, digital signatures are used to authenticate all other messages as well.) The protocol requires a minimal set-up: a common random string r, independent of the players’ keys. (In Algorand, r is actually replaced by the quantity Qr.) Protocol BBA⋆is a 3-step loop, where the players repeatedly exchange Boolean values, and different players may exit this loop at different times. A player i exits this loop by propagating, at some step, either a special value 0∗or a special value 1∗, thereby instructing all players to “pretend” they respectively receive 0 and 1 from i in all future steps. (Alternatively said: assume
that the last message received by a player j from another player i was a bit b. Then, in any step in which he does not receive any message from i, j acts as if i sent him the bit b.) The protocol uses a counter \(\gamma\), representing how many times its 3-step loop has been executed. At the start of BBA⋆, \(\gamma = 0\). (One may think of \(\gamma\) as a global counter, but it is actually increased by each individual player every time that the loop is executed.) There are \(n \geq 3t + 1\), where \(t\) is the maximum possible number of malicious players. A binary string \(x\) is identified with the integer whose binary representation (with possible leadings 0s) is \(x\); and \(\text{lsb}(x)\) denotes the least significant bit of \(x\). Protocol BBA⋆ (Communication) Step 1. [Coin-Fixed-To-0 Step] Each player \(i\) sends \(b_i\). 1.1 If \(\#_i^1(0) \geq 2t + 1\), then \(i\) sets \(b_i = 0\), sends \(0^*\), outputs \(\text{out}_i = 0\), and HALTS. 1.2 If \(\#_i^1(1) \geq 2t + 1\), then \(i\) sets \(b_i = 1\). 1.3 Else, \(i\) sets \(b_i = 0\). (Communication) Step 2. [Coin-Fixed-To-1 Step] Each player \(i\) sends \(b_i\). 2.1 If \(\#_i^2(1) \geq 2t + 1\), then \(i\) sets \(b_i = 1\), sends \(1^*\), outputs \(\text{out}_i = 1\), and HALTS. 2.2 If \(\#_i^2(0) \geq 2t + 1\), then \(i\) sets \(b_i = 0\). 2.3 Else, \(i\) sets \(b_i = 1\). (Communication) Step 3. [Coin-Genuinely-Flipped Step] Each player \(i\) sends \(b_i\) and \(\text{SIG}_i(r, \gamma)\). 3.1 If \(\#_i^3(0) \geq 2t + 1\), then \(i\) sets \(b_i = 0\). 3.2 If \(\#_i^3(1) \geq 2t + 1\), then \(i\) sets \(b_i = 1\). 3.3 Else, letting \(S_i = \{j \in N \text{ who have sent } i \text{ a proper message in this step 3}\}\), \(i\) sets \(b_i = c \triangleq \text{lsb}(\min_{j \in S_i} H(\text{SIG}_i(r, \gamma)))\); increases \(\gamma_i\) by 1; and returns to Step 1. Theorem 3.1. Whenever \(n \geq 3t + 1\), BBA⋆ is a binary \((n, t)\)-BA protocol with soundness 1. A proof of Theorem 3.1 is given in [26]. Its adaptation to our setting, and its player-replaceability property are novel. Historical Remark Probabilistic binary BA protocols were first proposed by Ben-Or in asynchronous settings [7]. Protocol BBA⋆is a novel adaptation, to our public-key setting, of the binary BA protocol of Feldman and Micali [15]. Their protocol was the first to work in an expected constant number of steps. It worked by having the players themselves implement a common coin, a notion proposed by Rabin, who implemented it via an external trusted party [32].
3.5 Graded Consensus and the Protocol GC Let us recall, for arbitrary values, a notion of consensus much weaker than Byzantine agreement. Definition 3.2. Let P be a protocol in which the set of all players is common knowledge, and each player i privately knows an arbitrary initial value v′ i. We say that \(P\) is an \((n, t)\)-graded consensus protocol if, in every execution with \(n\) players, at most \(t\) of which are malicious, every honest player \(i\) halts outputting a value-grade pair \((v_i, g_i)\), where \(g_i \in \{0, 1, 2\}\), so as to satisfy the following three conditions: 1. For all honest players \(i\) and \(j\), \(|g_i - g_j| \leq 1\). 2. For all honest players \(i\) and \(j\), \(g_i, g_j > 0 \Rightarrow v_i = v_j\). 3. If \(v'_1 = \cdots = v'_n = v\) for some value \(v\), then \(v_i = v\) and \(g_i = 2\) for all honest players \(i\). Historical Note The notion of a graded consensus is simply derived from that of a graded broadcast, put forward by Feldman and Micali in [15], by strengthening the notion of a crusader agreement, as introduced by Dolev [12], and refined by Turpin and Coan [33].8 In [15], the authors also provided a 3-step (n, t)-graded broadcasting protocol, gradecast, for \(n \geq 3t + 1\). A more complex \((n, t)\)-graded-broadcasting protocol for \(n > 2t + 1\) has later been found by Katz and Koo [19]. The following two-step protocol GC consists of the last two steps of gradecast, expressed in our notation. To emphasize this fact, and to match the steps of protocol Algorand ′ of section 4.1, we respectively name 2 and 3 the steps of GC. Protocol GC Step 2. Each player i sends v′ i to all players. Step 3. Each player \(i\) sends to all players the string \(x\) if and only if \(\#_i^2(x) \geq 2t + 1\). Output Determination. Each player \(i\) outputs the pair \((v_i, g_i)\) computed as follows: • If, for some \(x\), \(\#_i^3(x) \geq 2t + 1\), then \(v_i = x\) and \(g_i = 2\). • If, for some \(x\), \(\#_i^3(x) \geq t + 1\), then \(v_i = x\) and \(g_i = 1\). • Else, \(v_i = \bot\) and \(g_i = 0\). Theorem 3.2. If \(n \geq 3t + 1\), then GC is a \((n, t)\)-graded broadcast protocol. The proof immediately follows from that of the protocol gradecast in [15], and is thus omitted.9 8In essence, in a graded-broadcasting protocol, (a) the input of every player is the identity of a distinguished player, the sender, who has an arbitrary value v as an additional private input, and (b) the outputs must satisfy the same properties 1 and 2 of graded consensus, plus the following property 3′: if the sender is honest, then vi = v and gi = 2 for all honest player i. 9Indeed, in their protocol, in step 1, the sender sends his own private value v to all players, and each player i lets v′ i consist of the value he has actually received from the sender in step 1.
3.6 The Protocol BA⋆ We now describe the arbitrary-value BA protocol BA⋆via the binary BA protocol BBA⋆and the graded-consensus protocol GC. Below, the initial value of each player i is v′ i. Protocol BA⋆ Steps 1 and 2. Each player i executes GC, on input v′ i, so as to compute a pair (vi, gi). Step 3, . . . Each player i executes BBA⋆—with initial input 0, if gi = 2, and 1 otherwise— so as to compute the bit outi. Output Determination. Each player \(i\) outputs \(v_i\), if \(\text{out}_i = 0\), and \(\bot\) otherwise. Theorem 3.3. Whenever \(n \geq 3t + 1\), BA⋆ is a \((n, t)\)-BA protocol with soundness 1. Proof. We first prove Consistency, and then Agreement. Proof of Consistency. Assume that, for some value \(v \in V\), \(v'\) i = v. Then, by property 3 of graded consensus, after the execution of GC, all honest players output (v, 2). Accordingly, 0 is the initial bit of all honest players in the end of the execution of BBA⋆. Thus, by the Agreement property of binary Byzantine agreement, at the end of the execution of BA⋆, outi = 0 for all honest players. This implies that the output of each honest player i in BA⋆is vi = v. ✷ Proof of Agreement. Since BBA⋆is a binary BA protocol, either (A) outi = 1 for all honest player i, or (B) outi = 0 for all honest player i. In case A, all honest players output \(\bot\) in BA⋆, and thus Agreement holds. Consider now case B. In this case, in the execution of BBA⋆, the initial bit of at least one honest player i is 0. (Indeed, if initial bit of all honest players were 1, then, by the Consistency property of BBA⋆, we would have outj = 1 for all honest j.) Accordingly, after the execution of GC, i outputs the pair (v, 2) for some value v. Thus, by property 1 of graded consensus, gj > 0 for all honest players j. Accordingly, by property 2 of graded consensus, vj = v for all honest players j. This implies that, at the end of BA⋆, every honest player j outputs v. Thus, Agreement holds also in case B. ✷ Since both Consistency and Agreement hold, BA⋆is an arbitrary-value BA protocol. Historical Note Turpin and Coan were the first to show that, for \(n \geq 3t + 1\), any binary \((n, t)\)-BA protocol can be converted to an arbitrary-value (n, t)-BA protocol. The reduction arbitrary-value Byzantine agreement to binary Byzantine agreement via graded consensus is more modular and cleaner, and simplifies the analysis of our Algorand protocol Algorand ′. Generalizing BA⋆for use in Algorand Algorand works even when all communication is via gossiping. However, although presented in a traditional and familiar communication network, so as to enable a better comparison with the prior art and an easier understanding, protocol BA⋆works also in gossiping networks. In fact, in our detailed embodiments of Algorand, we shall present it directly for gossiping networks. We shall also point out that it satisfies the player replaceability property that is crucial for Algorand to be secure in the envisaged very adversarial model.
Any BA player-replaceable protocol working in a gossiping communication network can be securely employed within the inventive Algorand system. In particular, Micali and Vaikunthanatan have extended BA⋆to work very efficiently also with a simple majority of honest players. That protocol too could be used in Algorand.
传统环境下的 BA 协议 BA⋆
正如已经强调的,拜占庭协议是 Algorand 的关键要素。确实是通过 使用这样的 BA 协议使得 Algorand 不受分叉的影响。然而,为了防止我们的 强大的对手,Algorand 必须依赖于满足新的玩家可替换性的 BA 协议 约束。此外,要使 Algorand 高效,这样的 BA 协议必须非常高效。 BA 协议最初是为理想化的通信模型、同步完整的通信模型而定义的。 网络(SC 网络)。这样的模型可以更简单地设计和分析 BA 协议。 6给定诚实百分比 h 和可接受的故障概率 F,Algorand 计算上限 N, 一个步骤中验证者的最大数量。因此,MP 假设仅需要在 n \(\leq\) N 时成立。 此外,如上所述,无论有多少其他消息可以同时传播,MP 假设都成立。 乔丹的。然而,正如我们将看到的,在 Algorand 中,消息在基本上不重叠的时间内传播 间隔,在此期间传播单个块,或者最多 N 个验证者传播一个小块(例如 200B) 消息。因此,我们可以用更弱但也更复杂的方式重申 MP 假设。 7例如,他可以立即获知诚实玩家发送的消息。因此,恶意用户 i′ 是 被要求与诚实用户 i 同时传播消息,总是可以基于以下条件选择自己的消息 m′ 消息 m 实际上是由 i 传播的。用分布式计算的术语来说,这种能力与冲刺有关 文学。因此,在本节中,我们为 SC 网络引入一种新的 BA 协议 BA⋆,并忽略 完全是球员可替换性的问题。 BA⋆协议是具有独立价值的贡献。 事实上,它是迄今为止已知的 SC 网络最有效的加密 BA 协议。 为了在我们的 Algorand 协议中使用它,我们稍微修改 BA⋆,以考虑到我们的不同 沟通模型和上下文,但请确保在第 X 节中强调如何使用 BA⋆ 在我们实际的协议 Algorand ' 内。 我们首先回顾一下 BA⋆ 的运作模式和拜占庭协议的概念。 3.1 同步完整网络和匹配对手 在 SC 网络中,有一个公共时钟,在每个积分时间 r = 1, 2,... 处滴答作响。 。 。 在每次点击 r 时,每个玩家 i 都会立即同时发送一个 留言先生 i,j(可能是空消息)发送给每个玩家 j,包括他自己。每个先生 收到 i,j 此时,玩家 j 单击 r + 1 以及发送者 i 的身份。 再次强调,在通信协议中,如果玩家遵循所有规定,那么他就是诚实的 指令,以及其他恶意行为。所有恶意玩家均被完全控制且完美 由对手协调,特别是立即收到所有发送给 恶意玩家,并选择他们发送的消息。 攻击者可以在任何奇怪的时间立即对任何诚实的用户进行恶意点击 他希望,仅受限于恶意玩家数量的可能上限。也就是说, 对手“不能干扰诚实用户 i 已经发送的消息”,这将是 照常交付。 对手还具有额外的能力,可以在每个偶数轮中立即看到 当前诚实玩家发送的消息,并立即使用该信息进行选择 恶意玩家同时发送的消息会打勾。 备注 • 对手的力量。上面的设定是非常对抗性的。事实上,在拜占庭协议中 文学作品中,许多场景都不太具有敌意。然而,一些更具对抗性的设置 也被考虑过,对手在看到诚实玩家发送的消息后,我 在给定时间单击 r,可以立即从网络上删除所有这些消息 损坏i,选择当前恶意i在单击r时发送的消息,并让它们 照常交付。对手的预期力量与他在我们的环境中所拥有的力量相匹配。 • 物理抽象。设想的通信模型抽象出一个更物理的模型, 其中每对玩家 (i, j) 通过单独的私有通信线路 li,j 连接。 也就是说,没有其他人可以注入、干扰或获取有关通过该消息发送的消息的信息 李杰。对手获取 li,j 的唯一方法是破坏 i 或 j。 • 隐私和身份验证。在 SC 网络中,消息隐私和身份验证得到保证 通过假设。相比之下,在我们的通信网络中,消息被传播 点对点之间,身份验证由数字签名保证,并且不存在隐私。 因此,要在我们的设置中采用协议 BA⋆,每条交换的消息都应该进行数字签名 (进一步确定发送的状态)。幸运的是,我们的 BA 协议 考虑在 Algorand 中使用不需要消息隐私。3.2 拜占庭协议的概念 拜占庭协议的概念是由 Pease Shostak 和 Lamport [31] 提出的 二进制情况,即每个初始值都由一位组成。不过很快就被延长了 为任意初始值。 (参见 Fischer [16] 以及 Chor 和 Dwork [10] 的调查。) 协议,我们指的是任意值协议。 定义 3.1。在同步网络中,设P为n个玩家协议,其玩家集是公共的 玩家之间的知识,t 是一个正整数,使得 n \(\geq\)2t + 1。 我们说 P 是一个 任意值(分别为二进制) (n, t) - 健全性 \(\sigma\) \(\varepsilon\)(0, 1) 的拜占庭协议 如果,对于每组不包含特殊符号 \(\bot\) 的值 V(分别,对于 V = {0, 1}),在 执行过程中,最多 t 个玩家是恶意的,并且每个玩家 i 都以 初始值 vi \(\in\)V ,每个诚实玩家 j 以概率 1 停止,输出一个值 outi \(\in\)V \(\cup\){\(\bot\)} 从而以至少 \(\sigma\) 的概率满足以下两个条件: 1. 协议:对于所有诚实玩家 i,存在 out \(\varepsilon\)V \(\cup\){\(\bot\)} 使得 outi = out。 2. 一致性:如果对于某个值 v \(\in\)V ,对于所有诚实的玩家 vi = v,则 out = v。 我们将 out 称为 P 的输出,将每个 outi 称为玩家 i 的输出。 3.3 BA 符号 # 在我们的 BA 协议中,玩家需要计算有多少玩家向他发送了给定消息 给定的步骤。因此,对于可能发送的每个可能值 v,
s
我(五) (或者当 s 清楚时只是#i(v))是 i 在步骤 s 中从其接收 v 的玩家 j 的数量。 回想一下,玩家 i 从每个玩家 j 接收到一条消息,如果 玩家是 n,那么,对于所有 i 和 s,P v#s i(v) = n。 3.4 二进制 BA 协议 BBA⋆ 在本节中,我们提出一个新的二进制 BA 协议 BBA⋆,它依赖于更多的诚实性 超过三分之二的玩家并且速度非常快:无论恶意玩家可能做什么, 每次执行其主循环都会使玩家以 1/3 的概率达成一致。 每个玩家都有自己的数字签名方案的公钥,满足唯一签名 财产。由于该协议旨在在同步完整网络上运行,因此没有 需要一个玩家我签署他的每条消息。 数字签名用于在步骤 3 中生成足够通用的随机位。(在 Algorand 中, 数字签名也用于验证所有其他消息。) 该协议需要一个最小的设置:一个公共随机字符串 r,独立于玩家的 键。 (在 Algorand 中,r 实际上被数量 Qr 代替。) BBA⋆协议是一个三步循环,玩家反复交换布尔值,并且 不同的玩家可能会在不同的时间退出这个循环。玩家 i 通过传播退出这个循环, 在某个步骤中,要么是特殊值 0,要么是特殊值 1,从而指示所有玩家 “假装”他们在以后的所有步骤中分别从 i 接收 0 和 1。 (或者说:假设玩家 j 从另一个玩家 i 收到的最后一条消息有点 b。然后,在任意一步 其中他没有收到来自 i 的任何消息,j 的行为就好像我向他发送了位 b。) 该协议使用计数器 \(\gamma\),表示其 3 步循环已执行的次数。 BBA⋆开始时,\(\gamma\) = 0。(人们可能认为\(\gamma\)是一个全局计数器,但实际上它是增加的 每次执行循环时由每个单独的玩家执行。) 有 n \(\geq\)3t + 1,其中 t 是恶意玩家的最大可能数量。一个二进制 字符串 x 用二进制表示形式(可能有前导 0)为 x 的整数来标识; lsb(x) 表示 x 的最低有效位。 协议BBA⋆ (通信) 步骤1. [币固定为0步骤] 每个玩家i发送bi。 1.1 如果#1 i (0) \(\geq\)2t + 1,则i设置bi = 0,发送0,输出outi = 0, 并停止。 1.2 如果#1 i(1)\(\geq\)2t+1,那么,则i设bi=1。 1.3 否则,i 设置 bi = 0。 (通信) 步骤2. [硬币固定为1步骤] 每个玩家i发送bi。 2.1 如果#2 i(1)\(\geq\)2t+1,则i设bi=1, 发送 1, 输出outi = 1, 并停止。 2.2 如果#2 i(0)\(\geq\)2t+1,则设bi=0。 2.3 否则,i 设置 bi = 1。 (通信)步骤3.[硬币翻转步骤]每个玩家i发送bi和SIGi(r,\(\gamma\))。 3.1 如果#3 i(0)\(\geq\)2t+1,则i设bi=0。 3.2 如果#3 i(1)\(\geq\)2t+1,则i设bi=1。 3.3 否则,令 Si = {j \(\in\)N 在步骤 3 中向 i 发送了正确的消息}, i 设 bi = c \(\triangleq\)lsb(minj\(\in\)Si H(SIGi(r, \(\gamma\))));将 \(\gamma\)i 增加 1;并返回步骤 1。 定理3.1。当 n \(\geq\)3t + 1 时,BBA⋆是一个二元 (n, t)-BA 协议,稳健性为 1。 定理 3.1 的证明在 [26] 中给出。它对我们的环境的适应以及玩家的可替换性 属性新颖。 历史评论 概率二进制 BA 协议首先由 Ben-Or 在 异步设置 [7]。 BBA⋆协议是对我们的公钥设置的新颖改编 Feldman 和 Micali [15] 的二进制 BA 协议。他们的协议是第一个按预期工作的协议 恒定的步数。它的工作原理是让玩家自己实现一个共同的硬币, 拉宾提出的概念,他通过外部受信任方 [32] 实施了该概念。3.5 分级共识和GC协议 让我们回想一下,对于任意值,共识的概念比拜占庭协议弱得多。 定义 3.2。设 P 是一个协议,其中所有参与者的集合都是共同知识,并且每个参与者 玩家 i 私下知道任意初始值 v′ 岛 我们说 P 是一个 (n, t) 分级共识协议,如果在 n 个玩家的每次执行中, 其中大多数 t 都是恶意的,每个诚实的玩家 i 都会停止输出价值等级对 (vi, gi), 其中gi \(\in\){0, 1, 2},从而满足以下三个条件: 1. 对于所有诚实的玩家 i 和 j,|gi −gj| \(\leq\)1。 2. 对于所有诚实玩家 i 和 j,gi, gj > 0 ⇒vi = vj。 3. 如果 v′ 1 = \(\cdots\) = v′ 对于某个值 v,n = v,则对于所有诚实玩家 i,vi = v 且 gi = 2。 历史注释 分级共识的概念只是源自分级共识的概念。 广播,由 Feldman 和 Micali 在 [15] 中提出,通过强化十字军的概念 协议,由 Dolev [12] 引入,并由 Turpin 和 Coan [33].8 完善 在 [15] 中,作者还提供了一个 3 步(n,t)分级广播协议,gradecast,用于 n\(\geq\)3t+1。后来发现了 n > 2t+1 的更复杂的 (n, t) 分级广播协议 作者:Katz 和 Koo [19]。 下面的两步协议 GC 由 Gradecast 的最后两步组成,用我们的表达式表示 符号。为了强调这一事实,并匹配第 4.1 节协议 Algorand ' 的步骤,我们 分别命名2和3的GC步骤。 气相色谱协议 步骤 2. 每个玩家 i 发送 v′ 我对所有玩家。 步骤 3. 每个玩家 i 向所有玩家发送字符串 x 当且仅当 #2 i(x)\(\geq\)2t+1。 输出确定。每个玩家 i 输出计算如下的对 (vi, gi): • 如果对于某些x,#3 i (x) \(\geq\)2t + 1,则 vi = x 且 gi = 2。 • 如果对于某些x,#3 i (x) \(\geq\)t + 1,则 vi = x 且 gi = 1。 • 否则,vi = \(\bot\)且gi = 0。 定理3.2。如果n\(\geq\)3t+1,则GC是一个(n,t)分级的广播协议。 该证明紧随 [15] 中协议等级广播的证明,因此被省略。9 8本质上,在分级广播协议中,(a) 每个玩家的输入都是杰出玩家的身份 玩家,发送者,具有任意值 v 作为附加私有输入,并且 (b) 输出必须满足 与分级共识的属性 1 和 2 相同,加上以下属性 3′:如果发送者是诚实的,则 vi = v 且 对于所有诚实的玩家 i,gi = 2。 9确实,在他们的协议中,在步骤 1 中,发送者将自己的私有值 v 发送给所有玩家,并且每个玩家都让 v′ i 由他在步骤 1 中实际从发送者收到的值组成。3.6 协议 BA⋆ 现在我们通过二进制 BA 协议 BBA⋆ 来描述任意值 BA 协议 BA⋆ 以及 分级共识协议 GC。下面,每个玩家i的初始值为v′ 岛 协议 BA⋆ 步骤 1 和 2. 每个玩家 i 在输入 v′ 上执行 GC i,从而计算一对(vi,gi)。 步骤 3,. 。 。每个玩家 i 执行 BBA⋆——如果 gi = 2,初始输入为 0,否则为 1——所以 来计算位outi。 输出确定。如果 outi = 0,则每个玩家 i 输出 vi,否则输出 \(\bot\)。 定理3.3。每当 n \(\geq\)3t + 1 时,BA⋆是一个稳健性为 1 的 (n, t)-BA 协议。 证明。我们首先证明一致性,然后证明一致性。 一致性证明。假设对于某个值 v \(\in\)V , v′ i = v. 那么,根据性质 3 分级共识,GC执行后,所有诚实玩家输出(v,2)。因此,0 是 BBA⋆执行结束时所有诚实玩家的最初一点。因此,根据协议 二进制拜占庭协议的属性,在 BA⋆ 执行结束时,对于所有诚实的人,outi = 0 玩家。这意味着 BA⋆ 中每个诚实玩家 i 的输出是 vi = v。 ✷ 协议证明。由于 BBA⋆ 是一个二进制 BA 协议, (A) 对于所有诚实玩家 i,outi = 1,或者 (B) 对于所有诚实的玩家 i,outi = 0。 在情况 A 中,所有诚实玩家都输出 \(\bot\) 为 BA⋆,因此协议成立。现在考虑情况 B。 这种情况下,在执行BBA⋆时,至少一个诚实玩家i的初始位为0。(事实上,如果 所有诚实玩家的初始位为 1,然后,根据 BBA⋆ 的一致性属性,我们将有 对于所有诚实的 j,outj = 1。)因此,在执行 GC 后,i 对某些输出对 (v, 2) 因此,根据分级共识的属性 1,对于所有诚实的玩家 j,gj > 0。因此,通过 分级共识的属性 2,对于所有诚实的玩家 j,vj = v。这意味着,在年底 BA⋆,每个诚实玩家 j 输出 v。因此,协议在情况 B 中也成立。 ✷ 由于一致性和一致性都成立,所以 BA⋆ 是一个任意值的 BA 协议。 历史注释 Turpin 和 Coan 第一个证明,对于 n \(\geq\)3t+1,任何二元 (n, t)-BA 协议可以转换为任意值 (n, t)-BA 协议。减少任意值 通过分级共识的拜占庭协议到二进制拜占庭协议更加模块化, 更干净,并简化了对 Algorand 协议 Algorand ' 的分析。 泛化 BA⋆用于 Algorand Algorand 即使所有通信都是通过 八卦。然而,尽管呈现在传统且熟悉的通信网络中,所以 为了更好地与现有技术进行比较并更容易理解,协议 BA⋆works 也在八卦网络中。事实上,在 Algorand 的详细实施例中,我们将呈现它 直接用于八卦网络。我们还应该指出,它满足球员的可替换性 在设想的非常对抗性的模型中,对于 Algorand 的安全至关重要的财产。
任何在八卦通信网络中工作的 BA 播放器可替换协议都可以是 在本发明的Algorand系统中安全地使用。特别是 Micali 和 Vaikunthanatan 已将 BA⋆ 扩展到与大多数诚实玩家的高效合作。那 协议也可以在 Algorand 中使用。
Two Embodiments of Algorand
Two Embodiments of Algorand
As discussed, at a very high level, a round of Algorand ideally proceeds as follows. First, a randomly selected user, the leader, proposes and circulates a new block. (This process includes initially selecting a few potential leaders and then ensuring that, at least a good fraction of the time, a single common leader emerges.) Second, a randomly selected committee of users is selected, and reaches Byzantine agreement on the block proposed by the leader. (This process includes that each step of the BA protocol is run by a separately selected committee.) The agreed upon block is then digitally signed by a given threshold (\(t_H\)) of committee members. These digital signatures are circulated so that everyone is assured of which is the new block. (This includes circulating the credential of the signers, and authenticating just the hash of the new block, ensuring that everyone is guaranteed to learn the block, once its hash is made clear.) In the next two sections, we present two embodiments of Algorand, \(\text{Algorand}'_1\) and \(\text{Algorand}'_2\), that work under a majority-of-honest-users assumption. In Section 8 we show how to adopts these embodiments to work under a honest-majority-of-money assumption. \(\text{Algorand}'_1\) only envisages that \(> 2/3\) of the committee members are honest. In addition, in \(\text{Algorand}'_1\), the number of steps for reaching Byzantine agreement is capped at a suitably high number, so that agreement is guaranteed to be reached with overwhelming probability within a fixed number of steps (but potentially requiring longer time than the steps of \(\text{Algorand}'_2\)). In the remote case in which agreement is not yet reached by the last step, the committee agrees on the empty block, which is always valid. \(\text{Algorand}'_2\) envisages that the number of honest members in a committee is always greater than or equal to a fixed threshold \(t_H\) (which guarantees that, with overwhelming probability, at least \(2/3\) of the committee members are honest). In addition, \(\text{Algorand}'_2\) allows Byzantine agreement to be reached in an arbitrary number of steps (but potentially in a shorter time than \(\text{Algorand}'_1\)). It is easy to derive many variants of these basic embodiments. In particular, it is easy, given \(\text{Algorand}'_2\), to modify \(\text{Algorand}'_1\) so as to enable to reach Byzantine agreement in an arbitrary number of steps. Both embodiments share the following common core, notations, notions, and parameters. 4.1 A Common Core Objectives Ideally, for each round \(r\), Algorand would satisfy the following properties: 1. Perfect Correctness. All honest users agree on the same block \(B_r\). 2. Completeness 1. With probability 1, the payset of \(B_r\), \(PAY^r\), is maximal.10 10Because paysets are defined to contain valid payments, and honest users to make only valid payments, a maximal \(PAY^r\) contains the "currently outstanding" payments of all honest users.
Of course, guaranteeing perfect correctness alone is trivial: everyone always chooses the official payset \(PAY^r\) to be empty. But in this case, the system would have completeness 0. Unfortunately, guaranteeing both perfect correctness and completeness 1 is not easy in the presence of malicious users. Algorand thus adopts a more realistic objective. Informally, letting \(h\) denote the percentage of users who are honest, \(h > 2/3\), the goal of Algorand is Guaranteeing, with overwhelming probability, perfect correctness and completeness close to \(h\). Privileging correctness over completeness seems a reasonable choice: payments not processed in one round can be processed in the next, but one should avoid forks, if possible. Led Byzantine Agreement Perfect Correctness could be guaranteed as follows. At the start of round \(r\), each user \(i\) constructs his own candidate block \(B^r_i\), and then all users reach Byzantine agreement on one candidate block. As per our introduction, the BA protocol employed requires a \(2/3\) honest majority and is player replaceable. Each of its step can be executed by a small and randomly selected set of verifiers, who do not share any inner variables. Unfortunately, this approach has no completeness guarantees. This is so, because the candidate blocks of the honest users are most likely totally different from each other. Thus, the ultimately agreed upon block might always be one with a non-maximal payset. In fact, it may always be the empty block, \(B_\varepsilon\), that is, the block whose payset is empty. well be the default, empty one. \(\text{Algorand}'\) avoids this completeness problem as follows. First, a leader for round \(r\), \(\ell_r\), is selected. Then, \(\ell_r\) propagates his own candidate block, \(B^r_{\ell_r}\). Finally, the users reach agreement on the block they actually receive from \(\ell_r\). Because, whenever \(\ell_r\) is honest, Perfect Correctness and Completeness 1 both hold, \(\text{Algorand}'\) ensures that \(\ell_r\) is honest with probability close to \(h\). (When the leader is malicious, we do not care whether the agreed upon block is one with an empty payset. After all, a malicious leader \(\ell_r\) might always maliciously choose \(B^r_{\ell_r}\) to be the empty block, and then honestly propagate it, thus forcing the honest users to agree on the empty block.) Leader Selection In Algorand's, the \(r\)th block is of the form \(B_r = (r, PAY^r, Q_r, H(B_{r-1})\). As already mentioned in the introduction, the quantity \(Q_{r-1}\) is carefully constructed so as to be essentially non-manipulatable by our very powerful Adversary. (Later on in this section, we shall provide some intuition about why this is the case.) At the start of a round \(r\), all users know the blockchain so far, \(B_0, \ldots, B_{r-1}\), from which they deduce the set of users of every prior round: that is, \(PK^1, \ldots, PK^{r-1}\). A potential leader of round \(r\) is a user \(i\) such that \[.\!H\!\left(\text{SIG}_i\!\left(r, 1, Q_{r-1}\right)\right) \leq p.\] Let us explain. Note that, since the quantity \(Q_{r-1}\) is part of block \(B_{r-1}\), and the underlying signature scheme satisfies the uniqueness property, \(\text{SIG}_i\!\left(r, 1, Q_{r-1}\right)\) is a binary string uniquely associated to \(i\) and \(r\). Thus, since \(H\) is a random oracle, \(H\!\left(\text{SIG}_i\!\left(r, 1, Q_{r-1}\right)\right)\) is a random 256-bit long string uniquely associated to \(i\) and \(r\). The symbol "." in front of \(H\!\left(\text{SIG}_i\!\left(r, 1, Q_{r-1}\right)\right)\) is the decimal (in our case, binary) point, so that \(r_i \triangleq .\!H\!\left(\text{SIG}_i\!\left(r, 1, Q_{r-1}\right)\right)\) is the binary expansion of a random 256-bit number between 0 and 1 uniquely associated to \(i\) and \(r\). Thus the probability that \(r_i\) is less than or equal to \(p\) is essentially \(p\). (Our potential-leader selection mechanism has been inspired by the micro-payment scheme of Micali and Rivest [28].) The probability \(p\) is chosen so that, with overwhelming (i.e., \(1 - F\)) probability, at least one potential verifier is honest. (If fact, \(p\) is chosen to be the smallest such probability.)
Note that, since \(i\) is the only one capable of computing his own signatures, he alone can determine whether he is a potential verifier of round 1. However, by revealing his own credential, \(\sigma^r_i \triangleq \text{SIG}_i\!\left(r, 1, Q_{r-1}\right)\), \(i\) can prove to anyone to be a potential verifier of round \(r\). The leader \(\ell_r\) is defined to be the potential leader whose hashed credential is smaller that the hashed credential of all other potential leader \(j\): that is, \(H(\sigma^{r,s}_{\ell_r}) \leq H(\sigma^{r,s}_j)\). Note that, since a malicious \(\ell_r\) may not reveal his credential, the correct leader of round \(r\) may never be known, and that, barring improbable ties, \(\ell_r\) is indeed the only leader of round \(r\). Let us finally bring up a last but important detail: a user \(i\) can be a potential leader (and thus the leader) of a round \(r\) only if he belonged to the system for at least \(k\) rounds. This guarantees the non-manipulatability of \(Q_r\) and all future Q-quantities. In fact, one of the potential leaders will actually determine \(Q_r\). Verifier Selection Each step \(s > 1\) of round \(r\) is executed by a small set of verifiers, \(SV^{r,s}\). Again, each verifier \(i \in SV^{r,s}\) is randomly selected among the users already in the system \(k\) rounds before \(r\), and again via the special quantity \(Q_{r-1}\). Specifically, \(i \in PK^{r-k}\) is a verifier in \(SV^{r,s}\), if \[.\!H\!\left(\text{SIG}_i\!\left(r, s, Q_{r-1}\right)\right) \leq p'.\] Once more, only \(i\) knows whether he belongs to \(SV^{r,s}\), but, if this is the case, he could prove it by exhibiting his credential \(\sigma^{r,s}_i \triangleq H(\text{SIG}_i\!\left(r, s, Q_{r-1}\right))\). A verifier \(i \in SV^{r,s}\) sends a message, \(m^{r,s}_i\), in step \(s\) of round \(r\), and this message includes his credential \(\sigma^{r,s}_i\), so as to enable the verifiers f the nest step to recognize that \(m^{r,s}_i\) is a legitimate step-\(s\) message. The probability \(p'\) is chosen so as to ensure that, in \(SV^{r,s}\), letting \(\#good\) be the number of honest users and \(\#bad\) the number of malicious users, with overwhelming probability the following two conditions hold. For embodiment \(\text{Algorand}'_1\): (1) \(\#good > 2 \cdot \#bad\) and (2) \(\#good + 4 \cdot \#bad < 2n\), where \(n\) is the expected cardinality of \(SV^{r,s}\). For embodiment \(\text{Algorand}'_2\): (1) \(\#good > t_H\) and (2) \(\#good + 2\#bad < 2t_H\), where \(t_H\) is a specified threshold. These conditions imply that, with sufficiently high probability, (a) in the last step of the BA protocol, there will be at least given number of honest players to digitally sign the new block \(B_r\), (b) only one block per round may have the necessary number of signatures, and (c) the used BA protocol has (at each step) the required \(2/3\) honest majority. Clarifying Block Generation If the round-\(r\) leader \(\ell_r\) is honest, then the corresponding block is of the form \[B_r = \left(r,\; PAY^r,\; \text{SIG}_{\ell_r}\!\left(Q_{r-1}\right),\; H\!\left(B_{r-1}\right)\right),\] where the payset \(PAY^r\) is maximal. (recall that all paysets are, by definition, collectively valid.) Else (i.e., if \(\ell_r\) is malicious), \(B_r\) has one of the following two possible forms: \[B_r = \left(r,\; PAY^r,\; \text{SIG}_i\!\left(Q_{r-1}\right),\; H\!\left(B_{r-1}\right)\right)\] and \[B_r = B^r_\varepsilon \triangleq \left(r,\; \varnothing,\; Q_{r-1},\; H\!\left(B_{r-1}\right)\right).\]
In the first form, \(PAY^r\) is a (non-necessarily maximal) payset and it may be \(PAY^r = \varnothing\); and \(i\) is a potential leader of round \(r\). (However, \(i\) may not be the leader \(\ell_r\). This may indeed happen if if \(\ell_r\) keeps secret his credential and does not reveal himself.) The second form arises when, in the round-\(r\) execution of the BA protocol, all honest players output the default value, which is the empty block \(B^r_\varepsilon\) in our application. (By definition, the possible outputs of a BA protocol include a default value, generically denoted by \(\bot\). See section 3.2.) Note that, although the paysets are empty in both cases, \(B_r = \left(r,\; \varnothing,\; \text{SIG}_i\!\left(Q_{r-1}\right),\; H\!\left(B_{r-1}\right)\right)\) and \(B^r_\varepsilon\) are syntactically different blocks and arise in two different situations: respectively, "all went smoothly enough in the execution of the BA protocol", and "something went wrong in the BA protocol, and the default value was output". Let us now intuitively describe how the generation of block \(B_r\) proceeds in round \(r\) of \(\text{Algorand}'\). In the first step, each eligible player, that is, each player \(i \in PK^{r-k}\), checks whether he is a potential leader. If this is the case, then \(i\) is asked, using of all the payments he has seen so far, and the current blockchain, \(B_0, \ldots, B_{r-1}\), to secretly prepare a maximal payment set, \(PAY^r_i\), and secretly assembles his candidate block, \(B_r = \left(r,\; PAY^r_i,\; \text{SIG}_i\!\left(Q_{r-1}\right),\; H\!\left(B_{r-1}\right)\right)\). That is, not only does he include in \(B^r_i\), as its second component the just prepared payset, but also, as its third component, his own signature of \(Q_{r-1}\), the third component of the last block, \(B_{r-1}\). Finally, he propagate his round-\(r\)-step-1 message, \(m^{r,1}_i\), which includes (a) his candidate block \(B^r_i\), (b) his proper signature of his candidate block (i.e., his signature of the hash of \(B^r_i\), and (c) his own credential \(\sigma^{r,1}_i\), proving that he is indeed a potential verifier of round \(r\). (Note that, until an honest \(i\) produces his message \(m^{r,1}_i\), the Adversary has no clue that \(i\) is a potential verifier. Should he wish to corrupt honest potential leaders, the Adversary might as well corrupt random honest players. However, once he sees \(m^{r,1}_i\), since it contains \(i\)'s credential, the Adversary knows and could corrupt \(i\), but cannot prevent \(m^{r,1}_i\), which is virally propagated, from reaching all users in the system.) In the second step, each selected verifier \(j \in SV^{r,2}\) tries to identify the leader of the round. Specifically, \(j\) takes the step-1 credentials, \(\sigma^{r,1}_{i_1}, \ldots, \sigma^{r,1}_{i_n}\), contained in the proper step-1 message \(m^{r,1}_i\) he has received; hashes all of them, that is, computes \(H\!\left(\sigma^{r,1}_{i_1}\right), \ldots, H\!\left(\sigma^{r,1}_{i_n}\right)\); finds the credential, \(\sigma^{r,1}_{\ell_j}\), whose hash is lexicographically minimum; and considers \(\ell^r_j\) to be the leader of round \(r\). Recall that each considered credential is a digital signature of \(Q_{r-1}\), that \(\text{SIG}_i\!\left(r, 1, Q_{r-1}\right)\) is uniquely determined by \(i\) and \(Q_{r-1}\), that \(H\) is random oracle, and thus that each \(H(\text{SIG}_i\!\left(r, 1, Q_{r-1}\right))\) is a random 256-bit long string unique to each potential leader \(i\) of round \(r\). From this we can conclude that, if the 256-bit string \(Q_{r-1}\) were itself randomly and independently selected, than so would be the hashed credentials of all potential leaders of round \(r\). In fact, all potential leaders are well defined, and so are their credentials (whether actually computed or not). Further, the set of potential leaders of round \(r\) is a random subset of the users of round \(r - k\), and an honest potential leader \(i\) always properly constructs and propagates his message \(m^r_i\), which contains \(i\)'s credential. Thus, since the percentage of honest users is \(h\), no matter what the malicious potential leaders might do (e.g., reveal or conceal their own credentials), the minimum hashed potential-leader credential belongs to a honest user, who is necessarily identified by everyone to be the leader \(\ell_r\) of the round \(r\). Accordingly, if the 256-bit string \(Q_{r-1}\) were itself randomly and independently selected, with probability exactly \(h\) (a) the leader \(\ell_r\) is honest and (b) \(\ell_j = \ell_r\) for all honest step-2 verifiers \(j\). In reality, the hashed credential are, yes, randomly selected, but depend on \(Q_{r-1}\), which is
not randomly and independently selected. We shall prove in our analysis, however, that \(Q_{r-1}\) is sufficiently non-manipulatable to guarantee that the leader of a round is honest with probability \(h'\) sufficiently close to \(h\): namely, \(h' > h^2(1 + h - h^2)\). For instance, if \(h = 80\%\), then \(h' > .7424\). Having identified the leader of the round (which they correctly do when the leader \(\ell_r\) is honest), the task of the step-2 verifiers is to start executing the BA using as initial values what they believe to be the block of the leader. Actually, in order to minimize the amount of communication required, a verifier \(j \in SV^{r,2}\) does not use, as his input value \(v'_j\) to the Byzantine protocol, the block \(B_j\) that he has actually received from \(\ell_j\) (the user \(j\) believes to be the leader), but the the leader, but the hash of that block, that is, \(v'_j = H(B_i)\). Thus, upon termination of the BA protocol, the verifiers of the last step do not compute the desired round-\(r\) block \(B_r\), but compute (authenticate and propagate) \(H(B_r)\). Accordingly, since \(H(B_r)\) is digitally signed by sufficiently many verifiers of the last step of the BA protocol, the users in the system will realize that \(H(B_r)\) is the hash of the new block. However, they must also retrieve (or wait for, since the execution is quite asynchronous) the block \(B_r\) itself, which the protocol ensures that is indeed available, no matter what the Adversary might do. Asynchrony and Timing \(\text{Algorand}'_1\) and \(\text{Algorand}'_2\) have a significant degree of asynchrony. This is so because the Adversary has large latitude in scheduling the delivery of the messages being propagated. In addition, whether the total number of steps in a round is capped or not, there is the variance contribute by the number of steps actually taken. As soon as he learns the certificates of \(B_0, \ldots, B_{r-1}\), a user \(i\) computes \(Q_{r-1}\) and starts working on round \(r\), checking whether he is a potential leader, or a verifier in some step \(s\) of round \(r\). Assuming that \(i\) must act at step \(s\), in light of the discussed asynchrony, \(i\) relies on various strategies to ensure that he has sufficient information before he acts. For instance, he might wait to receive at least a given number of messages from the verifiers of the previous step, or wait for a sufficient time to ensure that he receives the messages of sufficiently many verifiers of the previous step. The Seed \(Q_r\) and the Look-Back Parameter \(k\) Recall that, ideally, the quantities \(Q_r\) should random and independent, although it will suffice for them to be sufficiently non-manipulatable by the Adversary. At a first glance, we could choose \(Q_{r-1}\) to coincide with \(H\!\left(PAY^{r-1}\right)\), and thus avoid to specify \(Q_{r-1}\) explicitly in \(B_{r-1}\). An elementary analysis reveals, however, that malicious users may take advantage of this selection mechanism.11 Some additional effort shows that myriads of other 11We are at the start of round \(r - 1\). Thus, \(Q_{r-2} = PAY^{r-2}\) is publicly known, and the Adversary privately knows who are the potential leaders he controls. Assume that the Adversary controls 10% of the users, and that, with very high probability, a malicious user \(w\) is the potential leader of round \(r - 1\). That is, assume that \(H\!\left(\text{SIG}_w\!\left(r - 2, 1, Q_{r-2}\right)\right)\) is so small that it is highly improbable an honest potential leader will actually be the leader of round \(r - 1\). (Recall that, since we choose potential leaders via a secret cryptographic sortition mechanism, the Adversary does not know who the honest potential leaders are.) The Adversary, therefore, is in the enviable position of choosing the payset \(PAY'\) he wants, and have it become the official payset of round \(r - 1\). However, he can do more. He can also ensure that, with high probability, () one of his malicious users will be the leader also of round \(r\), so that he can freely select what \(PAY^r\) will be. (And so on. At least for a long while, that is, as long as these high-probability events really occur.) To guarantee (), the Adversary acts as follows. Let \(PAY'\) be the payset the Adversary prefers for round \(r - 1\). Then, he computes \(H(PAY')\) and checks whether, for some already malicious player \(z\), \(\text{SIG}_z(r, 1, H(PAY'))\) is particularly small, that is, small enough that with very high probability \(z\) will be the leader of round \(r\). If this is the case, then he instructs \(w\) to choose his candidate block to be
alternatives, based on traditional block quantities are easily exploitable by the Adversary to ensure that malicious leaders are very frequent. We instead specifically and inductively define our brand new quantity \(Q_r\) so as to be able to prove that it is non-manipulatable by the Adversary. Namely, \(Q_r \triangleq H(\text{SIG}_{\ell_r}(Q_{r-1}), r)\), if \(B_r\) is not the empty block, and \(Q_r \triangleq H(Q_{r-1}, r)\) otherwise. The intuition of why this construction of \(Q_r\) works is as follows. Assume for a moment that \(Q_{r-1}\) is truly randomly and independently selected. Then, will so be \(Q_r\)? When \(\ell_r\) is honest the answer is (roughly speaking) yes. This is so because \[H(\text{SIG}_{\ell_r}(\cdot), r) : \{0, 1\}^{256} \longrightarrow \{0, 1\}^{256}\] is a random function. When \(\ell_r\) is malicious, however, \(Q_r\) is no longer univocally defined from \(Q_{r-1}\) and \(\ell_r\). There are at least two separate values for \(Q_r\). One continues to be \(Q_r \triangleq H(\text{SIG}_{\ell_r}(Q_{r-1}), r)\), and the other is \(H(Q_{r-1}, r)\). Let us first argue that, while the second choice is somewhat arbitrary, a second choice is absolutely mandatory. The reason for this is that a malicious \(\ell_r\) can always cause totally different candidate blocks to be received by the honest verifiers of the second step.12 Once this is the case, it is easy to ensure that the block ultimately agreed upon via the BA protocol of round \(r\) will be the default one, and thus will not contain anyone's digital signature of \(Q_{r-1}\). But the system must continue, and for this, it needs a leader for round \(r\). If this leader is automatically and openly selected, then the Adversary will trivially corrupt him. If it is selected by the previous \(Q_{r-1}\) via the same process, than \(\ell_r\) will again be the leader in round \(r+1\). We specifically propose to use the same secret cryptographic sortition mechanism, but applied to a new Q-quantity: namely, \(H(Q_{r-1}, r)\). By having this quantity to be the output of \(H\) guarantees that the output is random, and by including \(r\) as the second input of \(H\), while all other uses of \(H\) have one or 3+ inputs, "guarantees" that such a \(Q_r\) is independently selected. Again, our specific choice of alternative \(Q_r\) does not matter, what matter is that \(\ell_r\) has two choice for \(Q_r\), and thus he can double his chances to have another malicious user as the next leader. The options for \(Q_r\) may even be more numerous for the Adversary who controls a malicious \(\ell_r\). For instance, let \(x\), \(y\), and \(z\) be three malicious potential leaders of round \(r\) such that \[H\!\left(\sigma^{r,1}_x\right) < H\!\left(\sigma^{r,1}_y\right) < H\!\left(\sigma^{r,1}_z\right)\] and \(H\!\left(\sigma^{r,1}_z\right)\) is particulary small. That is, so small that there is a good chance that \(H\!\left(\sigma^{r,1}_z\right)\) is smaller of the hashed credential of every honest potential leader. Then, by asking \(x\) to hide his credential, the Adversary has a good chance of having \(y\) become the leader of round \(r - 1\). This implies that he has another option for \(Q_r\): namely, \(\text{SIG}_y\!\left(Q_{r-1}\right)\). Similarly, the Adversary may ask both \(x\) and \(y\) of withholding their credentials, so as to have \(z\) become the leader of round \(r - 1\) and gaining another option for \(Q_r\): namely, \(\text{SIG}_z\!\left(Q_{r-1}\right)\). Of course, however, each of these and other options has a non-zero chance to fail, because the Adversary cannot predict the hash of the digital signatures of the honest potential users. \(B^{r-1}_i = (r - 1, PAY', H(B_{r-2})\). Else, he has two other malicious users \(x\) and \(y\) to keep on generating a new payment \(\wp'\), from one to the other, until, for some malicious user \(z\) (or even for some fixed user \(z\)) \(H(\text{SIG}_z(PAY' \cup \{\wp\}))\) is particularly small too. This experiment will stop quite quickly. And when it does the Adversary asks \(w\) to propose the candidate block \(B^{r-1}_i = (r - 1, PAY' \cup \{\wp\}, H(B_{r-2})\). 12For instance, to keep it simple (but extreme), "when the time of the second step is about to expire", \(\ell_r\) could directly email a different candidate block \(B_i\) to each user \(i\). This way, whoever the step-2 verifiers might be, they will have received totally different blocks.
A careful, Markov-chain-like analysis shows that, no matter what options the Adversary chooses to make at round \(r - 1\), as long as he cannot inject new users in the system, he cannot decrease the probability of an honest user to be the leader of round \(r + 40\) much below \(h\). This is the reason for which we demand that the potential leaders of round \(r\) are users already existing in round \(r - k\). It is a way to ensure that, at round \(r - k\), the Adversary cannot alter by much the probability that an honest user become the leader of round \(r\). In fact, no matter what users he may add to the system in rounds \(r - k\) through \(r\), they are ineligible to become potential leaders (and a fortiori the leader) of round \(r\). Thus the look-back parameter \(k\) ultimately is a security parameter. (Although, as we shall see in section 7, it can also be a kind of "convenience parameter" as well.) Ephemeral Keys Although the execution of our protocol cannot generate a fork, except with negligible probability, the Adversary could generate a fork, at the \(r\)th block, after the legitimate block \(r\) has been generated. Roughly, once \(B_r\) has been generated, the Adversary has learned who the verifiers of each step of round \(r\) are. Thus, he could therefore corrupt all of them and oblige them to certify a new block \(\overset{f}{B_r}\). Since this fake block might be propagated only after the legitimate one, users that have been paying attention would not be fooled.13 Nonetheless, \(\overset{f}{B_r}\) would be syntactically correct and we want to prevent from being manufactured. We do so by means of a new rule. Essentially, the members of the verifier set \(SV^{r,s}\) of a step \(s\) of round \(r\) use ephemeral public keys \(pk^{r,s}_i\) to digitally sign their messages. These keys are single-use-only and their corresponding secret keys \(sk^{r,s}_i\) are destroyed once used. This way, if a verifier is corrupted later on, the Adversary cannot force him to sign anything else he did not originally sign. Naturally, we must ensure that it is impossible for the Adversary to compute a new key \(\overset{g}{p}{}^{r,s}_i\) and convince an honest user that it is the right ephemeral key of verifier \(i \in SV^{r,s}\) to use in step \(s\). 4.2 Common Summary of Notations, Notions, and Parameters Notations - \(r \geq 0\): the current round number. - \(s \geq 1\): the current step number in round \(r\). - \(B_r\): the block generated in round \(r\). - \(PK^r\): the set of public keys by the end of round \(r - 1\) and at the beginning of round \(r\). - \(S^r\): the system status by the end of round \(r - 1\) and at the beginning of round \(r\).14 - \(PAY^r\): the payset contained in \(B_r\). - \(\ell_r\): round-\(r\) leader. \(\ell_r\) chooses the payset \(PAY^r\) of round \(r\) (and determines the next \(Q_r\)). - \(Q_r\): the seed of round \(r\), a quantity (i.e., binary string) that is generated at the end of round \(r\) and is used to choose verifiers for round \(r + 1\). \(Q_r\) is independent of the paysets in the blocks and cannot be manipulated by \(\ell_r\). 13Consider corrupting the news anchor of a major TV network, and producing and broadcasting today a newsreel showing secretary Clinton winning the last presidential election. Most of us would recognize it as a hoax. But someone getting out of a coma might be fooled. 14In a system that is not synchronous, the notion of "the end of round \(r - 1\)" and "the beginning of round \(r\)" need to be carefully defined. Mathematically, \(PK^r\) and \(S^r\) are computed from the initial status \(S^0\) and the blocks \(B_1, \ldots, B_{r-1}\).
- \(SV^{r,s}\): the set of verifiers chosen for step \(s\) of round \(r\).
- \(SV^r\): the set of verifiers chosen for round \(r\), \(SV^r = \cup_{s \geq 1} SV^{r,s}\).
- \(MSV^{r,s}\) and \(HSV^{r,s}\): respectively, the set of malicious verifiers and the set of honest verifiers in \(SV^{r,s}\). \(MSV^{r,s} \cup HSV^{r,s} = SV^{r,s}\) and \(MSV^{r,s} \cap HSV^{r,s} = \varnothing\).
- \(n_1 \in \mathbb{Z}^+\) and \(n \in \mathbb{Z}^+\): respectively, the expected numbers of potential leaders in each \(SV^{r,1}\), and the expected numbers of verifiers in each \(SV^{r,s}\), for \(s > 1\). Notice that \(n_1 \ll n\), since we need at least one honest honest member in \(SV^{r,1}\), but at least a majority of honest members in each \(SV^{r,s}\) for \(s > 1\).
- \(h \in (0, 1)\): a constant greater than \(2/3\). \(h\) is the honesty ratio in the system. That is, the fraction of honest users or honest money, depending on the assumption used, in each \(PK^r\) is at least \(h\).
- \(H\): a cryptographic hash function, modelled as a random oracle.
- \(\bot\): A special string of the same length as the output of \(H\).
- \(F \in (0, 1)\): the parameter specifying the allowed error probability. A probability \(\leq F\) is considered "negligible", and a probability \(\geq 1 - F\) is considered "overwhelming".
- \(p_h \in (0, 1)\): the probability that the leader of a round \(r\), \(\ell_r\), is honest. Ideally \(p_h = h\). With the existence of the Adversary, the value of \(p_h\) will be determined in the analysis.
- \(k \in \mathbb{Z}^+\): the look-back parameter. That is, round \(r - k\) is where the verifiers for round \(r\) are chosen from — namely, \(SV^r \subseteq PK^{r-k}\).15
- \(p_1 \in (0, 1)\): for the first step of round \(r\), a user in round \(r - k\) is chosen to be in \(SV^{r,1}\) with probability \(p_1 \triangleq \frac{n_1}{|PK^{r-k}|}\).
- \(p \in (0, 1)\): for each step \(s > 1\) of round \(r\), a user in round \(r - k\) is chosen to be in \(SV^{r,s}\) with probability \(p \triangleq \frac{n}{|PK^{r-k}|}\).
- \(CERT^r\): the certificate for \(B_r\). It is a set of \(t_H\) signatures of \(H(B_r)\) from proper verifiers in round \(r\).
- \(\overline{B_r} \triangleq (B_r, CERT^r)\) is a proven block. A user \(i\) knows \(\overline{B_r}\) if he possesses (and successfully verifies) both parts of the proven block. Note that the \(CERT^r\) seen by different users may be different.
- \(\tau^r_i\): the (local) time at which a user \(i\) knows \(\overline{B_r}\). In the Algorand protocol each user has his own clock. Different users' clocks need not be synchronized, but must have the same speed. Only for the purpose of the analysis, we consider a reference clock and measure the players' related times with respect to it.
- \(\alpha^{r,s}_i\) and \(\beta^{r,s}_i\): respectively the (local) time a user \(i\) starts and ends his execution of Step \(s\) of round \(r\).
- \(\Lambda\) and \(\lambda\): essentially, the upper-bounds to, respectively, the time needed to execute Step 1 and the time needed for any other step of the Algorand protocol. Parameter \(\Lambda\) upper-bounds the time to propagate a single 1MB block. (In our notation, \(\Lambda = \lambda_{\rho, 1\text{MB}}\). Recalling our notation, that we set \(\rho = 1\) for simplicity, and that blocks are chosen to be at most 1MB-long, we have \(\Lambda = \lambda_{1,1,1\text{MB}}\).) 15Strictly speaking, "\(r - k\)" should be "\(\max\{0, r - k\}\)".
Parameter \(\lambda\) upperbounds the time to propagate one small message per verifier in a Step \(s > 1\). (Using, as in Bitcoin, elliptic curve signatures with 32B keys, a verifier message is 200B long. Thus, in our notation, \(\lambda = \lambda_{n, \rho, 200\text{B}}\).) We assume that \(\Lambda = O(\lambda)\). Notions - Verifier selection. For each round \(r\) and step \(s > 1\), \(SV^{r,s} \triangleq \{i \in PK^{r-k} : .\!H(\text{SIG}_i(r, s, Q_{r-1})) \leq p\}\). Each user \(i \in PK^{r-k}\) privately computes his signature using his long-term key and decides whether \(i \in SV^{r,s}\) or not. If \(i \in SV^{r,s}\), then \(\text{SIG}_i(r, s, Q_{r-1})\) is \(i\)'s \((r, s)\)-credential, compactly denoted by \(\sigma^{r,s}_i\). For the first step of round \(r\), \(SV^{r,1}\) and \(\sigma^{r,1}_i\) are similarly defined, with \(p\) replaced by \(p_1\). The verifiers in \(SV^{r,1}\) are potential leaders. - Leader selection. User \(i \in SV^{r,1}\) is the leader of round \(r\), denoted by \(\ell_r\), if \(H(\sigma^{r,1}_i) \leq H(\sigma^{r,1}_j)\) for all potential leaders \(j \in SV^{r,1}\). Whenever the hashes of two players' credentials are compared, in the unlikely event of ties, the protocol always breaks ties lexicographically according to the (long-term public keys of the) potential leaders. By definition, the hash value of player \(\ell_r\)'s credential is also the smallest among all users in \(PK^{r-k}\). Note that a potential leader cannot privately decide whether he is the leader or not, without seeing the other potential leaders' credentials. Since the hash values are uniform at random, when \(SV^{r,1}\) is non-empty, \(\ell_r\) always exists and is honest with probability at least \(h\). The parameter \(n_1\) is large enough so as to ensure that each \(SV^{r,1}\) is non-empty with overwhelming probability. - Block structure. A non-empty block is of the form \(B_r = (r, PAY^r, \text{SIG}_{\ell_r}(Q_{r-1}), H(B_{r-1}))\), and an empty block is of the form \(B^r_\varepsilon = (r, \varnothing, Q_{r-1}, H(B_{r-1}))\). Note that a non-empty block may still contain an empty payset \(PAY^r\), if no payment occurs in this round or if the leader is malicious. However, a non-empty block implies that the identity of \(\ell_r\), his credential \(\sigma^{r,1}_{\ell_r}\) and \(\text{SIG}_{\ell_r}(Q_{r-1})\) have all been timely revealed. The protocol guarantees that, if the leader is honest, then the block will be non-empty with overwhelming probability. - Seed \(Q_r\). If \(B_r\) is non-empty, then \(Q_r \triangleq H(\text{SIG}_{\ell_r}(Q_{r-1}), r)\), otherwise \(Q_r \triangleq H(Q_{r-1}, r)\). Parameters - Relationships among various parameters. — The verifiers and potential leaders of round \(r\) are selected from the users in \(PK^{r-k}\), where \(k\) is chosen so that the Adversary cannot predict \(Q_{r-1}\) back at round \(r - k - 1\) with probability better than \(F\): otherwise, he will be able to introduce malicious users for round \(r - k\), all of which will be potential leaders/verifiers in round \(r\), succeeding in
having a malicious leader or a malicious majority in \(SV^{r,s}\) for some steps \(s\) desired by him. — For Step 1 of each round \(r\), \(n_1\) is chosen so that with overwhelming probability, \(SV^{r,1} \neq \varnothing\). - Example choices of important parameters. — The outputs of \(H\) are 256-bit long. — \(h = 80\%\), \(n_1 = 35\). — \(\Lambda = 1\) minute and \(\lambda = 10\) seconds. - Initialization of the protocol. The protocol starts at time 0 with \(r = 0\). Since there does not exist "\(B_{-1}\)" or "\(CERT^{-1}\)", syntactically \(B_{-1}\) is a public parameter with its third component specifying \(Q_{-1}\), and all users know \(B_{-1}\) at time 0.
Algorand 的两个实施例
正如所讨论的,在非常高的水平上,一轮 Algorand 理想地按如下方式进行。首先,随机一个
选定的用户(领导者)提议并流通一个新区块。
(这个过程最初包括
选择一些潜在的领导者,然后确保至少在大部分时间里,
出现单一的共同领导者。)其次,随机选择一个用户委员会,并且
就领导者提出的区块达成拜占庭协议。 (这个过程包括
BA 协议的每一步均由单独选定的委员会运行。)商定的区块
然后由给定阈值 (TH) 的委员会成员进行数字签名。这些数字签名
进行流通,以便每个人都可以确定哪个是新区块。 (这包括流通
签名者的凭证,并仅验证新区块的 hash,确保每个人
一旦明确了 hash ,就保证能够学习该块。)
在接下来的两节中,我们将介绍 Algorand、Algorand ' 的两个实施例
1 和 Algorand ′
2、
在大多数诚实用户的假设下工作。在第 8 节中,我们展示了如何采用这些
在诚实多数资金假设下工作的实施例。
Algorand '
1 仅假设 > 2/3 的委员会成员是诚实的。此外,在
Algorand ′
1、达成拜占庭协议的步骤数被限制在适当高的水平
数,因此保证在一定时间内以压倒性的概率达成协议
固定步骤数(但可能需要比 Algorand ' 的步骤更长的时间
2)。在
在最后一步尚未达成协议的极少数情况下,委员会同意
空块,始终有效。
Algorand ′
2 假设委员会中诚实成员的数量总是大于
或等于固定阈值 tH (这保证了,以压倒性的概率,至少
2/3的委员会成员是诚实的)。另外,Algorand ′
2 允许拜占庭协议
可以通过任意数量的步骤达到(但可能比 Algorand ' 更短的时间
1)。
很容易得出这些基本实施例的许多变体。特别是,这很容易,因为
Algorand ′
2、修改Algorand′
1 以便能够任意达成拜占庭协议
步数。
两个实施例共享以下共同核心、符号、概念和参数。
4.1
共同核心
目标
理想情况下,对于每一轮 r,Algorand 将满足以下属性:
1. 完美的正确性。所有诚实的用户都同意同一个区块。
2. 完整性 1. 在概率 1 的情况下,Br、PAY r 的支付集最大。10
10由于支付集被定义为包含有效支付,并且诚实的用户只进行有效支付,因此最大
PAY r 包含所有诚实用户的“当前未偿”付款。当然,仅仅保证完美的正确性是微不足道的:每个人总是选择官方的
付款集 PAY r 为空。但在这种情况下,系统的完整性为 0。不幸的是,
保证完美的正确性和完整性 1 在存在恶意的情况下并不容易
用户。 Algorand 因此采用了更现实的目标。非正式地,让 h 表示百分比
诚实的用户中,h > 2/3,Algorand 的目标是
以压倒性的概率保证接近 h 的完美正确性和完整性。
优先考虑正确性而不是完整性似乎是一个合理的选择:付款未在
一轮可以在下一轮中处理,但如果可能的话,应该避免分叉。
领导拜占庭协议
完美的正确性可以保证如下。一开始
在第r轮中,每个用户i构建自己的候选块Br
i ,然后所有用户都到达拜占庭
就一个候选区块达成一致。根据我们的介绍,所采用的 BA 协议需要
2/3 诚实多数,并且是玩家可替换的。它的每个步骤都可以由一个小的和
随机选择一组验证者,他们不共享任何内部变量。
不幸的是,这种方法没有完整性保证。之所以如此,是因为候选人
诚实用户的群体很可能彼此完全不同。因此,最终
商定的区块可能总是具有非最大支付集的区块。事实上,它可能永远是
空块,B\(\varepsilon\),即支付集为空的块。我们将默认为空。
Algorand ' 避免了这种完整性问题,如下所示。首先,选择 r 轮的领导者 \(\ell\)r。
然后,\(\ell\)r 传播他自己的候选块 Br
\(\ell\)r。最后,用户就区块达成一致
他们实际上是从 \(\ell\)r 收到的。因为,只要 \(\ell\)r 是诚实的,就具有完美的正确性和完整性
1 都成立,Algorand ′ 确保 \(\ell\)r 是诚实的,概率接近 h。 (当领导者
恶意的,我们不关心商定的区块是否是一个具有空支付集的区块。毕竟,一个
恶意领导者 \(\ell\)r 可能总是恶意选择 Br
\(\ell\)r 是空块,然后诚实地
传播它,从而迫使诚实的用户就空块达成一致。)
领导者选拔
在 Algorand 中,第 r 个块的形式为 Br = (r, PAY r, Qr, H(Br−1)。
正如引言中已经提到的,数量 Qr−1 被仔细构造为
基本上无法被我们非常强大的对手操纵。 (在本节后面,我们将
提供一些关于为什么会出现这种情况的直觉。)在一轮 r 开始时,所有用户都知道
blockchain 到目前为止,B0,. 。 。 , Br−1,他们从中推导出前一轮的用户集:
是,PK1,. 。 。 , PKr−1。第 r 轮的潜在领导者是用户 i,使得
.H
西吉
r, 1, Qr−1
\(\leq\)p。
让我们解释一下。
请注意,由于数量 Qr−1 是块 Br−1 的一部分,并且底层
签名方案满足唯一性属性 SIGi
r, 1, Qr−1
是唯一的二进制字符串
与 i 和 r 相关。因此,由于 H 是随机的 oracle,H
西吉
r, 1, Qr−1
是一个随机的256位
与 i 和 r 唯一关联的长字符串。符号“.”在H前面
西吉
r, 1, Qr−1
是
小数(在我们的例子中为二进制)点,因此 ri \(\triangleq\).H
西吉
r, 1, Qr−1
是 a 的二元展开式
与 i 和 r 唯一关联的 0 到 1 之间的随机 256 位数字。因此概率
ri 小于或等于 p 本质上是 p。 (我们的潜在领导者选择机制已经
受到 Micali 和 Rivest [28] 的小额支付计划的启发。)
选择概率 p,以便以压倒性的(即 1 −F)概率,至少有一个
潜在的验证者是诚实的。 (事实上,p 被选为此类概率中最小的。)请注意,由于 i 是唯一能够计算自己签名的人,因此他独自一人可以
确定他是否是第一轮的潜在验证者。但是,通过透露他自己的凭据,
\(\sigma\)r
我\(\triangleq\)SIGi
r, 1, Qr−1
,我可以向任何人证明自己是 r 轮的潜在验证者。
领导者 \(\ell\)r 被定义为潜在领导者,其 hashed 凭证小于
hashed 所有其他潜在领导者 j 的凭证:即 H(\(\sigma\)r,s
\(\ell\)r ) \(\leq\)H(\(\sigma\)r,s
j)。
请注意,由于恶意 \(\ell\)r 可能不会透露他的凭证,因此第 r 轮的正确领导者可能会
永远不会被知道,除非有不可能的联系,\(\ell\)r确实是r轮的唯一领导者。
最后让我们提出最后一个但重要的细节:用户 i 可以成为潜在的领导者(因此
仅当他属于该系统至少 k 轮时,才是 r 轮的领导者。这保证了
Qr 和所有未来 Q 量的不可操纵性。事实上,潜在的领导者之一
实际上将确定 Qr。
验证者选择
r 轮的每个步骤 s > 1 都由一小组验证者 SV r,s 执行。
同样,每个验证者 i \(\in\)SV r,s 都是从系统中已有 k 轮的用户中随机选择的
在 r 之前,再次通过特殊量 Qr−1。具体来说,i \(\in\)PKr−k 是 SV r,s 中的验证者,如果
.H
西吉
r, s, Qr−1
\(\leq\)p′。
再一次,只有我知道他是否属于 SV r,s,但是,如果是这样,他可以通过以下方式证明这一点:
展示他的证书 \(\sigma\)r,s
我
\(\triangleq\)H(SIGi
r, s, Qr−1
)。验证者 i \(\in\)SV r,s 发送消息 mr,s
我,在
r 轮的步骤 s,该消息包含他的凭证 \(\sigma\)r,s
i ,以便使验证者能够
下一步要认识到 Mr,s
我
是合法的step-s消息。
选择概率 p' 以确保在 SV r,s 中,令 #good 为
诚实用户和#bad 恶意用户的数量,以下的概率是压倒性的
两个条件成立。
对于实施例Algorand'
1:
(1) #好 > 2 \(\cdot\) #坏并且
(2) #good + 4 \(\cdot\) #bad < 2n,其中 n 是 SV r,s 的预期基数。
对于实施例Algorand'
2:
(1) #good > tH 且
(2) #good + 2#bad < 2tH,其中 tH 是指定阈值。
这些条件意味着,以足够高的概率,(a) 在 BA 的最后一步中
协议中,至少会有给定数量的诚实玩家对新区块 Br 进行数字签名,
(b) 每轮只有一个区块可能具有必要数量的签名,以及 (c) 使用的 BA
协议(在每一步)拥有所需的 2/3 诚实多数。
澄清区块生成
如果 r 轮领导者 \(\ell\)r 是诚实的,则相应的区块
是这样的形式
溴=
r, PAY r, SIG\(\ell\)r Qr−1
, H
Br−1
,
其中支付集 PAY r 是最大的。 (回想一下,根据定义,所有支付集集体有效。)
否则(即,如果 \(\ell\)r 是恶意的),Br 具有以下两种可能形式之一:
溴=
r、支付 r、SIGi
Qr−1
, H
Br−1
和
溴 = 溴
\(\varepsilon\) \(\triangleq\)
r, \(\emptyset\), Qr−1, H
Br−1
。在第一种形式中,PAY r 是一个(不一定是最大的)支付集,它可能是 PAY r = \(\emptyset\);我是
r 轮的潜在领导者。 (然而,我可能不是领导者\(\ell\)r。如果如果
\(\ell\)r 对他的凭证保密并且不暴露自己。)
第二种形式出现在 BA 协议的 R 轮执行中,所有诚实的参与者
输出默认值,即空块Br
\(\varepsilon\) 在我们的应用中。 (根据定义,可能的
BA 协议的输出包括默认值,一般用 \(\bot\) 表示。参见第 3.2 节。)
请注意,虽然两种情况下的支付集都是空的,但 Br =
r, \(\emptyset\), SIGi
Qr−1
, H
Br−1
和溴
\(\varepsilon\) 是语法上不同的块,出现在两种不同的情况下:分别是“所有
BA 协议的执行过程非常顺利”,并且“在执行过程中出现了问题”
BA协议,默认值为output”。
现在让我们直观地描述一下Algorand′的第r轮区块Br的生成是如何进行的。
第一步,每个符合条件的玩家,即每个玩家 i \(\in\) PKr−k,检查他是否是潜在的
领导者。如果是这种情况,那么我会被问到,使用他迄今为止看到的所有付款,以及
当前 blockchain,B0,. 。 。 ,Br−1,秘密准备最大支付集,PAY r
我,并且偷偷地
组装他的候选块,Br =
r,支付 r
我,SIGi
Qr−1
, H
Br−1
。也就是说,他不仅
包含在 Br 中
i ,作为其第二个组成部分,即刚刚准备好的支付集,而且,作为其第三个组成部分,
他自己的 Qr−1 签名,最后一个区块 Br−1 的第三个组成部分。最后他宣扬自己的
round-r-step-1 消息,先生,1
i ,其中包括 (a) 他的候选块 Br
i , (b) 他的正确签名
他的候选块的(即他对 Br 的 hash 的签名)
i 和 (c) 他自己的凭证 \(\sigma\)r,1
我,证明
他确实是 r 轮的潜在验证者。
(请注意,直到诚实的 i 发出他的消息 mr,1
i ,对手不知道我是
潜在的验证者。如果他想腐蚀诚实的潜在领导人,对手也可以
腐败的随机诚实玩家。然而,一旦他看到 Mr,1
i ,因为它包含 i 的凭证,
对手知道并可能腐蚀 i,但无法阻止 mr,1
i ,通过病毒传播,来自
覆盖系统中的所有用户。)
在第二步中,每个选定的验证者 j \(\in\)SV r,2 尝试识别该轮的领导者。
具体来说,j 采用第 1 步凭证 \(\sigma\)r,1
i1 , . 。 。 , \(\sigma\)r,1
中,包含在正确的步骤 1 消息 mr,1 中
我
他已经收到; hashes 全部,即计算 H
\(\sigma\)r,1
i1
, . 。 。 , H
\(\sigma\)r,1
在
;找到凭证,
\(\sigma\)r,1
\(\ell\)j ,其 hash 按字典顺序最小;并考虑 \(\ell\)r
j 成为 r 轮的领导者。
回想一下,每个考虑的凭证都是 Qr−1 的数字签名,即 SIGi
r, 1, Qr−1
是
由 i 和 Qr−1 唯一确定,H 是随机的 oracle,因此每个 H(SIGi
r, 1, Qr−1
是 r 轮中每个潜在领导者 i 唯一的随机 256 位长字符串。
由此我们可以得出结论,如果 256 位字符串 Qr−1 本身是随机且独立的
选择后,r 轮所有潜在领导者的 hashed 证书将被选中。事实上,所有
潜在的领导者是明确定义的,他们的资历也是如此(无论是实际计算的还是
不是)。此外,第 r 轮的潜在领导者集合是第 r 轮用户的随机子集
r −k,作为一个诚实的潜在领导者,我总是正确地构建和传播他的信息,先生
我,
其中包含我的凭据。因此,由于诚实用户的百分比为 h,无论
恶意的潜在领导者可能会这样做(例如,透露或隐藏自己的凭据),最低限度
hashed 潜在领导者凭证属于诚实的用户,每个人都必然会识别他
成为 r 轮的领导者 \(\ell\)r。因此,如果 256 位字符串 Qr−1 本身是随机的并且
独立选择,概率为 h (a) 领导者 \(\ell\)r 是诚实的,并且 (b) \(\ell\)j = \(\ell\)r 对于所有人
诚实的第 2 步验证者 j.
实际上,hashed 凭证是随机选择的,但取决于 Qr−1,即不是随机和独立选择的。然而,我们将在分析中证明 Qr−1 是
足够不可操纵以保证一轮的领导者在概率上是诚实的
h′ 足够接近 h:即 h′ > h2(1 + h −h2)。例如,如果 h = 80%,则 h′ > .7424。
确定了本轮的领导者(当领导者 \(\ell\)r 诚实时,他们正确地做到了这一点),
步骤 2 验证者的任务是开始执行 BA,使用他们认为的初始值
成为领导者的块。实际上,为了尽量减少所需的沟通量,
验证者 j \(\in\)SV r,2 不使用,作为他的输入值 v′
j 到拜占庭协议,块 Bj
他实际上已经收到了来自\(\ell\)j(用户j认为是领导者)的信息,但是领导者,但是
该块的 hash,即 v′
j = H(Bi)。因此,在 BA 协议终止后,验证者
最后一步的不计算所需的 round-r 块 Br,而是计算(验证和
传播)H(Br)。因此,由于 H(Br) 是由足够多的验证者进行数字签名的
BA协议的最后一步,系统中的用户将意识到H(Br)是新的hash
块。然而,它们还必须检索(或等待,因为执行是完全异步的)
阻止 Br 本身,协议确保其确实可用,无论对手如何
可能会。
异步和定时
Algorand ′
1 和 Algorand ′
2 具有显着程度的异步性。
之所以如此,是因为对手在安排消息传递方面有很大的自由度
传播。另外,一轮中的总步数是否有上限,还有
方差由实际采取的步数贡献。
一旦他获得了 B0 的证书,. 。 。 , Br−1,用户 i 计算 Qr−1 并开始工作
在第r轮上,检查他是否是潜在的领导者,或者是第r轮的某些步骤中的验证者。
假设我必须在步骤 s 采取行动,鉴于所讨论的异步性,我依赖于各种
确保他在采取行动之前拥有足够的信息的策略。
例如,他可能会等待从验证者处接收至少给定数量的消息
上一步,或者等待足够的时间以确保他收到足够的消息
上一步的许多验证者。
种子 Qr 和回溯参数 k
回想一下,理想情况下,Qr 的数量应该
随机且独立,尽管它们足够不可被操纵
对手。
乍一看,我们可以选择 Qr−1 与 H 一致
支付 r−1
,从而避免
在 Br−1 中明确指定 Qr−1。然而,基本分析表明,恶意用户可能
利用这种选择机制。11 一些额外的努力表明,无数其他
11我们正处于第 r -1 轮的开始。因此,Qr−2 = PAY r−2 是公开的,而对手则是私下的
知道他控制的潜在领导者是谁。
假设攻击者控制 10% 的用户,并且
恶意用户 w 很有可能成为第 r -1 轮的潜在领导者。也就是说,假设
H
信号发生器
r−2, 1, Qr−2
规模如此之小,以至于诚实的潜在领导者实际上不太可能成为
r -1 轮的领导者。 (回想一下,由于我们通过秘密的加密抽签机制选择潜在的领导者,
对手不知道谁是诚实的潜在领导者。)因此,对手处于令人羡慕的境地
选择他想要的支付集 PAY ′ 的位置,并使其成为第 r -1 轮的正式支付集。然而,
他可以做得更多。他还可以确保()他的恶意用户之一将很有可能成为领导者
也是 r 轮的,这样他就可以自由选择 PAY r 是什么。 (等等。至少在很长一段时间内,也就是说,
只要这些高概率事件确实发生。)为了保证(),对手的行为如下。让支付′
是对手在第 r -1 轮中偏好的支付集。然后,他计算 H(PAY ′) 并检查是否对于某些
已经是恶意玩家 z,SIGz(r, 1, H(PAY ′)) 特别小,即足够小,以至于具有很高的
z 概率将成为 r 轮的领先者。如果是这种情况,那么他指示 w 选择他的候选块基于传统区块数量的替代方案很容易被对手利用,以确保
恶意领导人非常频繁。相反,我们具体地、归纳地定义我们的品牌
新数量 Qr 以便能够证明它是不可被对手操纵的。即,
如果 Br 不是空块,则 Qr \(\triangleq\)H(SIG\(\ell\)r(Qr−1), r),否则 Qr \(\triangleq\)H(Qr−1, r)。
Qr 的这种构造为何有效的直觉如下。暂时假设
Qr−1 是真正随机且独立选择的。那么Qr也会如此吗?当 \(\ell\)r 诚实时
答案是(粗略地说)是的。之所以如此是因为
H(SIG\(\ell\)r( \(\cdot\) ), r) : {0, 1}256 −→{0, 1}256
是一个随机函数。然而,当 \(\ell\)r 是恶意的时,Qr 不再由 Qr−1 唯一定义
和\(\ell\)r。 Qr 至少有两个单独的值。继续为 Qr \(\triangleq\)H(SIG\(\ell\)r(Qr−1), r),
另一个是H(Qr−1,r)。首先我们要论证的是,虽然第二个选择有些武断,
第二选择是绝对强制性的。原因是恶意的 \(\ell\)r 总是会导致
第二步的诚实验证者将接收完全不同的候选块。12 一旦
确实如此,通过 BA 协议很容易确保该区块最终达成一致
r 轮将是默认轮次,因此不会包含任何人的 Qr−1 数字签名。但是
该系统必须继续下去,为此,它需要 r 轮的领导者。如果这个领导者自动
并公开选择,那么对手就会轻易地腐蚀他。如果是之前选择的
Qr−1 通过相同的过程,\(\ell\)r 将再次成为 r+1 轮中的领先者。我们特别建议
使用相同的秘密加密抽签机制,但应用于新的 Q 数量:即,
H(Qr−1, r)。通过将此量作为 H 的输出,可以保证输出是随机的,
并通过将 r 作为 H 的第二个输入,而 H 的所有其他用途都有一个或 3 个以上输入,
“保证”这样的 Qr 是独立选择的。同样,我们对替代 Qr 的具体选择
没关系,重要的是\(\ell\)r对于Qr有两种选择,这样他的机会就可以加倍
让另一个恶意用户作为下一个领导者。
对于控制恶意 \(\ell\)r 的对手来说,Qr 的选项甚至可能更多。
例如,令 x、y 和 z 为 r 轮的三个恶意潜在领导者,使得
H
\(\sigma\)r,1
x
<H
\(\sigma\)r,1
y
对于某些步骤 s 所期望的,在 SV r,s 中拥有恶意领导者或恶意多数 他。 — 对于每轮 r 的步骤 1,选择 n1 以便以压倒性的概率获得 SV r,1 ̸= \(\emptyset\)。 • 重要参数的选择示例。 — H 的输出长度为 256 位。 — h = 80%,n1 = 35。 — Λ = 1 分钟且 \(\lambda\) = 10 秒。 • 协议的初始化。 协议从时间 0 开始,r = 0。由于不存在“B−1”或“CERT −1”, 从语法上讲,B−1 是一个公共参数,其第三个组件指定 Q−1,并且所有用户 在时间 0 知道 B−1。
Algorand ′
\(\text{Algorand}^\prime\)
1 In this section, we construct a version of \(\text{Algorand}^\prime\) working under the following assumption. Honest Majority of Users Assumption: More than 2/3 of the users in each \(PK^r\) are honest. In Section 8, we show how to replace the above assumption with the desired Honest Majority of Money assumption. 5.1 Additional Notations and Parameters Notations • \(m \in \mathbb{Z}^+\): the maximum number of steps in the binary BA protocol, a multiple of 3. • \(L_r \leq m/3\): a random variable representing the number of Bernoulli trials needed to see a 1, when each trial is 1 with probability \(\frac{p_h}{2}\) and there are at most \(m/3\) trials. If all trials fail then \(L_r \triangleq m/3\). \(L_r\) will be used to upper-bound the time needed to generate block \(B_r\). • \(t_H = \frac{2n}{3} + 1\): the number of signatures needed in the ending conditions of the protocol. • \(CERT_r\): the certificate for \(B_r\). It is a set of \(t_H\) signatures of \(H(B_r)\) from proper verifiers in round \(r\). Parameters • Relationships among various parameters. — For each step \(s > 1\) of round \(r\), \(n\) is chosen so that, with overwhelming probability, \(|HSV^{r,s}| > 2|MSV^{r,s}|\) and \(|HSV^{r,s}| + 4|MSV^{r,s}| < 2n\). The closer to 1 the value of \(h\) is, the smaller \(n\) needs to be. In particular, we use (variants of) Chernoffbounds to ensure the desired conditions hold with overwhelming probability. — \(m\) is chosen such that \(L_r < m/3\) with overwhelming probability. • Example choices of important parameters. — \(F = 10^{-12}\). — \(n \approx 1500\), \(k = 40\) and \(m = 180\).
5.2 Implementing Ephemeral Keys in \(\text{Algorand}'_1\)
As already mentioned, we wish that a verifier \(i \in SV^{r,s}\) digitally signs his message \(m_i^{r,s}\) of step \(s\) in round \(r\), relative to an ephemeral public key \(pk_i^{r,s}\), using an ephemeral secrete key \(sk_i^{r,s}\) that he promptly destroys after using. We thus need an efficient method to ensure that every user can verify that \(pk_i^{r,s}\) is indeed the key to use to verify \(i\)'s signature of \(m_i^{r,s}\). We do so by a (to the best of our knowledge) new use of identity-based signature schemes. At a high level, in such a scheme, a central authority A generates a public master key, PMK, and a corresponding secret master key, SMK. Given the identity, U, of a player U, A computes, via SMK, a secret signature key skU relative to the public key U, and privately gives skU to U. (Indeed, in an identity-based digital signature scheme, the public key of a user U is U itself!) This way, if A destroys SMK after computing the secret keys of the users he wants to enable to produce digital signatures, and does not keep any computed secret key, then U is the only one who can digitally sign messages relative to the public key U. Thus, anyone who knows “U’s name”, automatically knows U’s public key, and thus can verify U’s signatures (possibly using also the public master key PMK). In our application, the authority A is user \(i\), and the set of all possible users U coincides with the round-step pair \((r, s)\) in —say— \(S = \{i\} \times \{r', \ldots, r' + 10^6\} \times \{1, \ldots, m+3\}\), where \(r'\) is a given round, and \(m + 3\) the upperbound to the number of steps that may occur within a round. This way, \(pk_i^{r,s} \triangleq (i, r, s)\), so that everyone seeing \(i\)'s signature \(\text{SIG}_{pk_i^{r,s}}^{r,s}(m_i^{r,s})\) can, with overwhelming probability, immediately verify it for the first million rounds \(r\) following \(r'\). In other words, \(i\) first generates \(PMK\) and \(SMK\). Then, he publicizes that \(PMK\) is \(i\)'s master public key for any round \(r \in [r', r' + 10^6]\), and uses \(SMK\) to privately produce and store the secret key \(sk_i^{r,s}\) for each triple \((i, r, s) \in S\). This done, he destroys \(SMK\). If he determines that he is not part of \(SV^{r,s}\), then \(i\) may leave \(sk_i^{r,s}\) alone (as the protocol does not require that he aunthenticates any message in Step \(s\) of round \(r\)). Else, \(i\) first uses \(sk_i^{r,s}\) to digitally sign his message \(m_i^{r,s}\), and then destroys \(sk_i^{r,s}\). Note that \(i\) can publicize his first public master key when he first enters the system. That is, the same payment \(\wp\) that brings \(i\) into the system (at a round \(r'\) or at a round close to \(r'\)), may also specify, at \(i\)'s request, that \(i\)'s public master key for any round \(r \in [r', r' + 10^6]\) is \(PMK\) —e.g., by including a pair of the form \((PMK, [r', r' + 10^6])\). Also note that, since \(m + 3\) is the maximum number of steps in a round, assuming that a round takes a minute, the stash of ephemeral keys so produced will last \(i\) for almost two years. At the same time, these ephemeral secret keys will not take \(i\) too long to produce. Using an elliptic-curve based system with 32B keys, each secret key is computed in a few microseconds. Thus, if \(m + 3 = 180\), then all 180M secret keys can be computed in less than one hour. When the current round is getting close to \(r' + 10^6\), to handle the next million rounds, \(i\) generates a new \((PMK', SMK')\) pair, and informs what his next stash of ephemeral keys is by —for example— having \(\text{SIG}_i(PMK', [r' + 10^6 + 1, r' + 2 \cdot 10^6 + 1])\) enter a new block, either as a separate "transaction" or as some additional information that is part of a payment. By so doing, \(i\) informs everyone that he/she should use \(PMK'\) to verify \(i\)'s ephemeral signatures in the next million rounds. And so on. (Note that, following this basic approach, other ways for implementing ephemeral keys without using identity-based signatures are certainly possible. For instance, via Merkle trees.16) 16In this method, \(i\) generates a public-secret key pair \((pk_i^{r,s}, sk_i^{r,s})\) for each round-step pair \((r, s)\) in —say—
Other ways for implementing ephemeral keys are certainly possible —e.g., via Merkle trees. 5.3 Matching the Steps of \(\text{Algorand}'_1\) with those of \(\text{BA}^\star\) As we said, a round in \(\text{Algorand}'_1\) has at most \(m + 3\) steps. Step 1. In this step, each potential leader \(i\) computes and propagates his candidate block \(B_i^r\), together with his own credential, \(\sigma_i^{r,1}\). Recall that this credential explicitly identifies \(i\). This is so, because \(\sigma_i^{r,1} \triangleq \text{SIG}_i(r, 1, Q_{r-1})\). Potential verifier \(i\) also propagates, as part of his message, his proper digital signature of \(H(B_i^r)\). Not dealing with a payment or a credential, this signature of \(i\) is relative to his ephemeral public key \(pk_i^{r,1}\): that is, he propagates \(\text{sig}_{pk_i^{r,1}}(H(B_i^r))\). Given our conventions, rather than propagating \(B_i^r\) and \(\text{sig}_{pk_i^{r,1}}(H(B_i^r))\), he could have propagated \(\text{SIG}_{pk_i^{r,1}}(H(B_i^r))\). However, in our analysis we need to have explicit access to \(\text{sig}_{pk_i^{r,1}}(H(B_i^r))\). Steps 2. In this step, each verifier \(i\) sets \(\ell_i^r\) to be the potential leader whose hashed credential is the smallest, and \(B_i^r\) to be the block proposed by \(\ell_i^r\). Since, for the sake of efficiency, we wish to agree on \(H(B_r)\), rather than directly on \(B_r\), \(i\) propagates the message he would have propagated in the first step of \(\text{BA}^\star\) with initial value \(v'_i = H(B_i^r)\). That is, he propagates \(v'_i\), after ephemerally signing it, of course. (Namely, after signing it relative to the right ephemeral public key, which in this case is \(pk_i^{r,2}\).) Of course too, \(i\) also transmits his own credential. Since the first step of \(\text{BA}^\star\) consists of the first step of the graded consensus protocol GC, Step 2 of \(\text{Algorand}^\prime\) corresponds to the first step of GC. Steps 3. In this step, each verifier \(i \in SV^{r,2}\) executes the second step of \(\text{BA}^\star\). That is, he sends the same message he would have sent in the second step of GC. Again, \(i\)'s message is ephemerally signed and accompanied by \(i\)'s credential. (From now on, we shall omit saying that a verifier ephemerally signs his message and also propagates his credential.) Step 4. In this step, every verifier \(i \in SV^{r,4}\) computes the output of GC, \((v_i, g_i)\), and ephemerally signs and sends the same message he would have sent in the third step of \(\text{BA}^\star\), that is, in the first step of \(\text{BBA}^\star\), with initial bit 0 if \(g_i = 2\), and 1 otherwise. Step \(s = 5, \ldots, m + 2\). Such a step, if ever reached, corresponds to step \(s - 1\) of \(\text{BA}^\star\), and thus to step \(s - 3\) of \(\text{BBA}^\star\). Since our propagation model is sufficiently asynchronous, we must account for the possibility that, in the middle of such a step \(s\), a verifier \(i \in SV^{r,s}\) is reached by information proving him that block \(B_r\) has already been chosen. In this case, \(i\) stops his own execution of round \(r\) of \(\text{Algorand}^\prime\), and starts executing his round-\((r + 1)\) instructions. \(\{r', \ldots, r' + 10^6\} \times \{1, \ldots, m + 3\}\). Then he orders these public keys in a canonical way, stores the \(j\)th public key in the \(j\)th leaf of a Merkle tree, and computes the root value \(R_i\), which he publicizes. When he wants to sign a message relative to key \(pk_i^{r,s}\), \(i\) not only provides the actual signature, but also the authenticating path for \(pk_i^{r,s}\) relative to \(R_i\). Notice that this authenticating path also proves that \(pk_i^{r,s}\) is stored in the \(j\)th leaf. The rest of the details can be easily filled.
Accordingly, the instructions of a verifier \(i \in SV^{r,s}\), in addition to the instructions corresponding to Step \(s - 3\) of \(\text{BBA}^\star\), include checking whether the execution of \(\text{BBA}^\star\) has halted in a prior Step \(s'\). Since \(\text{BBA}^\star\) can only halt is a Coin-Fixed-to-0 Step or in a Coin-Fixed-to-1 step, the instructions distinguish whether A (Ending Condition 0): \(s' - 2 \equiv 0 \bmod 3\), or B (Ending Condition 1): \(s' - 2 \equiv 1 \bmod 3\). In fact, in case A, the block \(B_r\) is non-empty, and thus additional instructions are necessary to ensure that \(i\) properly reconstructs \(B_r\), together with its proper certificate \(CERT_r\). In case B, the block \(B_r\) is empty, and thus \(i\) is instructed to set \(B_r = B_\epsilon^r = (r, \emptyset, H(Q_{r-1}, r), H(B_{r-1}))\), and to compute \(CERT_r\). If, during his execution of step \(s\), \(i\) does not see any evidence that the block \(B_r\) has already been generated, then he sends the same message he would have sent in step \(s - 3\) of \(\text{BBA}^\star\). Step \(m + 3\). If, during step \(m + 3\), \(i \in SV^{r,m+3}\) sees that the block \(B_r\) was already generated in a prior step \(s'\), then he proceeds just as explained above. Else, rather then sending the same message he would have sent in step \(m\) of \(\text{BBA}^\star\), \(i\) is instructed, based on the information in his possession, to compute \(B_r\) and its corresponding certificate \(CERT_r\). Recall, in fact, that we upperbound by \(m + 3\) the total number of steps of a round. 5.4 The Actual Protocol Recall that, in each step \(s\) of a round \(r\), a verifier \(i \in SV^{r,s}\) uses his long-term public-secret key pair to produce his credential, \(\sigma_i^{r,s} \triangleq \text{SIG}_i(r, s, Q_{r-1})\), as well as \(\text{SIG}_i(Q_{r-1})\) in case \(s = 1\). Verifier \(i\) uses his ephemeral secret key \(sk_i^{r,s}\) to sign his \((r, s)\)-message \(m_i^{r,s}\). For simplicity, when \(r\) and \(s\) are clear, we write \(esig_i(x)\) rather than \(sig_{pk_i^{r,s}}(x)\) to denote \(i\)'s proper ephemeral signature of a value \(x\) in step \(s\) of round \(r\), and write \(\text{ESIG}_i(x)\) instead of \(\text{SIG}_{pk_i^{r,s}}(x)\) to denote \((i, x, esig_i(x))\). Step 1: Block Proposal Instructions for every user \(i \in PK^{r-k}\): User \(i\) starts his own Step 1 of round \(r\) as soon as he knows \(B_{r-1}\). \(\bullet\) User \(i\) computes \(Q_{r-1}\) from the third component of \(B_{r-1}\) and checks whether \(i \in SV^{r,1}\) or not. \(\bullet\) If \(i \notin SV^{r,1}\), then \(i\) stops his own execution of Step 1 right away. \(\bullet\) If \(i \in SV^{r,1}\), that is, if \(i\) is a potential leader, then he collects the round-\(r\) payments that have been propagated to him so far and computes a maximal payset \(PAY_i^r\) from them. Next, he computes his "candidate block" \(B_i^r = (r, PAY_i^r, \text{SIG}_i(Q_{r-1}), H(B_{r-1}))\). Finally, he computes the message \(m_i^{r,1} = (B_i^r, esig_i(H(B_i^r)), \sigma_i^{r,1})\), destroys his ephemeral secret key \(sk_i^{r,1}\), and then propagates \(m_i^{r,1}\).
Remark. In practice, to shorten the global execution of Step 1, it is important that the \((r, 1)\)- messages are selectively propagated. That is, for every user \(i\) in the system, for the first \((r, 1)\)- message that he ever receives and successfully verifies,17 player \(i\) propagates it as usual. For all the other \((r, 1)\)-messages that player \(i\) receives and successfully verifies, he propagates it only if the hash value of the credential it contains is the smallest among the hash values of the credentials contained in all \((r, 1)\)-messages he has received and successfully verified so far. Furthermore, as suggested by Georgios Vlachos, it is useful that each potential leader \(i\) also propagates his credential \(\sigma_i^{r,1}\) separately: those small messages travel faster than blocks, ensure timely propagation of the \(m_j^{r,1}\)'s where the contained credentials have small hash values, while make those with large hash values disappear quickly. Step 2: The First Step of the Graded Consensus Protocol \(\text{GC}\) Instructions for every user \(i \in PK^{r-k}\): User \(i\) starts his own Step 2 of round \(r\) as soon as he knows \(B_{r-1}\). \(\bullet\) User \(i\) computes \(Q_{r-1}\) from the third component of \(B_{r-1}\) and checks whether \(i \in SV^{r,2}\) or not. \(\bullet\) If \(i \notin SV^{r,2}\) then \(i\) stops his own execution of Step 2 right away. \(\bullet\) If \(i \in SV^{r,2}\), then after waiting an amount of time \(t_2 \triangleq \lambda + \Lambda\), \(i\) acts as follows. 1. He finds the user \(\ell\) such that \(H(\sigma_\ell^{r,1}) \leq H(\sigma_j^{r,1})\) for all credentials \(\sigma_j^{r,1}\) that are part of the successfully verified \((r, 1)\)-messages he has received so far.a 2. If he has received from \(\ell\) a valid message \(m_\ell^{r,1} = (B_\ell^r, esig_\ell(H(B_\ell^r)), \sigma_\ell^{r,1})\),b then \(i\) sets \(v'_i \triangleq H(B_\ell^r)\); otherwise \(i\) sets \(v'_i \triangleq \bot\). 3. \(i\) computes the message \(m_i^{r,2} \triangleq (\text{ESIG}_i(v'_i), \sigma_i^{r,2})\),c destroys his ephemeral secret key \(sk_i^{r,2}\), and then propagates \(m_i^{r,2}\). aEssentially, user \(i\) privately decides that the leader of round \(r\) is user \(\ell\). bAgain, player \(\ell\)'s signatures and the hashes are all successfully verified, and \(PAY_\ell^r\) in \(B_\ell^r\) is a valid payset for round \(r\) —although \(i\) does not check whether \(PAY_\ell^r\) is maximal for \(\ell\) or not. cThe message \(m_i^{r,2}\) signals that player \(i\) considers \(v'_i\) to be the hash of the next block, or considers the next block to be empty. 17That is, all the signatures are correct and both the block and its hash are valid —although \(i\) does not check whether the included payset is maximal for its proposer or not.
Step 3: The Second Step of \(\text{GC}\) Instructions for every user \(i \in PK^{r-k}\): User \(i\) starts his own Step 3 of round \(r\) as soon as he knows \(B_{r-1}\). \(\bullet\) User \(i\) computes \(Q_{r-1}\) from the third component of \(B_{r-1}\) and checks whether \(i \in SV^{r,3}\) or not. \(\bullet\) If \(i \notin SV^{r,3}\), then \(i\) stops his own execution of Step 3 right away. \(\bullet\) If \(i \in SV^{r,3}\), then after waiting an amount of time \(t_3 \triangleq t_2 + 2\lambda = 3\lambda + \Lambda\), \(i\) acts as follows. 1. If there exists a value \(v' \neq \bot\) such that, among all the valid messages \(m_j^{r,2}\) he has received, more than \(2/3\) of them are of the form \((\text{ESIG}_j(v'), \sigma_j^{r,2})\), without any contradiction,a then he computes the message \(m_i^{r,3} \triangleq (\text{ESIG}_i(v'), \sigma_i^{r,3})\). Otherwise, he computes \(m_i^{r,3} \triangleq (\text{ESIG}_i(\bot), \sigma_i^{r,3})\). 2. \(i\) destroys his ephemeral secret key \(sk_i^{r,3}\), and then propagates \(m_i^{r,3}\). aThat is, he has not received two valid messages containing \(\text{ESIG}_j(v')\) and a different \(\text{ESIG}_j(v'')\) respectively, from a player \(j\). Here and from here on, except in the Ending Conditions defined later, whenever an honest player wants messages of a given form, messages contradicting each other are never counted or considered valid.
Step 4: Output of \(\text{GC}\) and The First Step of \(\text{BBA}^\star\) Instructions for every user \(i \in PK^{r-k}\): User \(i\) starts his own Step 4 of round \(r\) as soon as he knows \(B_{r-1}\). \(\bullet\) User \(i\) computes \(Q_{r-1}\) from the third component of \(B_{r-1}\) and checks whether \(i \in SV^{r,4}\) or not. \(\bullet\) If \(i \notin SV^{r,4}\), then \(i\) his stops his own execution of Step 4 right away. \(\bullet\) If \(i \in SV^{r,4}\), then after waiting an amount of time \(t_4 \triangleq t_3 + 2\lambda = 5\lambda + \Lambda\), \(i\) acts as follows. 1. He computes \(v_i\) and \(g_i\), the output of \(\text{GC}\), as follows. (a) If there exists a value \(v' \neq \bot\) such that, among all the valid messages \(m_j^{r,3}\) he has received, more than \(2/3\) of them are of the form \((\text{ESIG}_j(v'), \sigma_j^{r,3})\), then he sets \(v_i \triangleq v'\) and \(g_i \triangleq 2\). (b) Otherwise, if there exists a value \(v' \neq \bot\) such that, among all the valid messages \(m_j^{r,3}\) he has received, more than \(1/3\) of them are of the form \((\text{ESIG}_j(v'), \sigma_j^{r,3})\), then he sets \(v_i \triangleq v'\) and \(g_i \triangleq 1\).a (c) Else, he sets \(v_i \triangleq H(B_\epsilon^r)\) and \(g_i \triangleq 0\). 2. He computes \(b_i\), the input of \(\text{BBA}^\star\), as follows: \(b_i \triangleq 0\) if \(g_i = 2\), and \(b_i \triangleq 1\) otherwise. 3. He computes the message \(m_i^{r,4} \triangleq (\text{ESIG}_i(b_i), \text{ESIG}_i(v_i), \sigma_i^{r,4})\), destroys his ephemeral secret key \(sk_i^{r,4}\), and then propagates \(m_i^{r,4}\). aIt can be proved that the \(v'\) in case (b), if exists, must be unique.
Step \(s\), \(5 \leq s \leq m + 2\), \(s - 2 \equiv 0 \bmod 3\): A Coin-Fixed-To-0 Step of \(\text{BBA}^\star\) Instructions for every user \(i \in PK^{r-k}\): User \(i\) starts his own Step \(s\) of round \(r\) as soon as he knows \(B_{r-1}\). \(\bullet\) User \(i\) computes \(Q_{r-1}\) from the third component of \(B_{r-1}\) and checks whether \(i \in SV^{r,s}\). \(\bullet\) If \(i \notin SV^{r,s}\), then \(i\) stops his own execution of Step \(s\) right away. \(\bullet\) If \(i \in SV^{r,s}\) then he acts as follows. – He waits until an amount of time \(t_s \triangleq t_{s-1} + 2\lambda = (2s - 3)\lambda + \Lambda\) has passed. – Ending Condition 0: If, during such waiting and at any point of time, there exists a string \(v \neq \bot\) and a step \(s'\) such that (a) \(5 \leq s' \leq s\), \(s' - 2 \equiv 0 \bmod 3\) —that is, Step \(s'\) is a Coin-Fixed-To-0 step, (b) \(i\) has received at least \(t_H = \frac{2n}{3} + 1\) valid messages \(m_j^{r,s'-1} = (\text{ESIG}_j(0), \text{ESIG}_j(v), \sigma_j^{r,s'-1})\),a and (c) \(i\) has received a valid message \(m_j^{r,1} = (B_j^r, esig_j(H(B_j^r)), \sigma_j^{r,1})\) with \(v = H(B_j^r)\), then, \(i\) stops his own execution of Step \(s\) (and in fact of round \(r\)) right away without propagating anything; sets \(B_r = B_j^r\); and sets his own \(\text{CERT}^r\) to be the set of messages \(m_j^{r,s'-1}\) of sub-step (b).b – Ending Condition 1: If, during such waiting and at any point of time, there exists a step \(s'\) such that (a') \(6 \leq s' \leq s\), \(s' - 2 \equiv 1 \bmod 3\) —that is, Step \(s'\) is a Coin-Fixed-To-1 step, and (b') \(i\) has received at least \(t_H\) valid messages \(m_j^{r,s'-1} = (\text{ESIG}_j(1), \text{ESIG}_j(v_j), \sigma_j^{r,s'-1})\),c then, \(i\) stops his own execution of Step \(s\) (and in fact of round \(r\)) right away without propagating anything; sets \(B_r = B_\epsilon^r\); and sets his own \(\text{CERT}^r\) to be the set of messages \(m_j^{r,s'-1}\) of sub-step (b'). – Otherwise, at the end of the wait, user \(i\) does the following. He sets \(v_i\) to be the majority vote of the \(v_j\)'s in the second components of all the valid \(m_j^{r,s-1}\)'s he has received. He computes \(b_i\) as follows. If more than \(2/3\) of all the valid \(m_j^{r,s-1}\)'s he has received are of the form \((\text{ESIG}_j(0), \text{ESIG}_j(v_j), \sigma_j^{r,s-1})\), then he sets \(b_i \triangleq 0\). Else, if more than \(2/3\) of all the valid \(m_j^{r,s-1}\)'s he has received are of the form \((\text{ESIG}_j(1), \text{ESIG}_j(v_j), \sigma_j^{r,s-1})\), then he sets \(b_i \triangleq 1\). Else, he sets \(b_i \triangleq 0\). He computes the message \(m_i^{r,s} \triangleq (\text{ESIG}_i(b_i), \text{ESIG}_i(v_i), \sigma_i^{r,s})\), destroys his ephemeral secret key \(sk_i^{r,s}\), and then propagates \(m_i^{r,s}\). aSuch a message from player \(j\) is counted even if player \(i\) has also received a message from \(j\) signing for 1. Similar things for Ending Condition 1. As shown in the analysis, this is done to ensure that all honest users know \(B_r\) within time \(\lambda\) from each other. bUser \(i\) now knows \(B_r\) and his own round \(r\) finishes. He still helps propagating messages as a generic user, but does not initiate any propagation as a \((r, s)\)-verifier. In particular, he has helped propagating all messages in his \(\text{CERT}^r\), which is enough for our protocol. Note that he should also set \(b_i \triangleq 0\) for the binary BA protocol, but \(b_i\) is not needed in this case anyway. Similar things for all future instructions. cIn this case, it does not matter what the \(v_j\)'s are.
Step \(s\), \(6 \leq s \leq m + 2\), \(s - 2 \equiv 1 \bmod 3\): A Coin-Fixed-To-1 Step of \(\text{BBA}^\star\) Instructions for every user \(i \in PK^{r-k}\): User \(i\) starts his own Step \(s\) of round \(r\) as soon as he knows \(B_{r-1}\). \(\bullet\) User \(i\) computes \(Q_{r-1}\) from the third component of \(B_{r-1}\) and checks whether \(i \in SV^{r,s}\) or not. \(\bullet\) If \(i \notin SV^{r,s}\), then \(i\) stops his own execution of Step \(s\) right away. \(\bullet\) If \(i \in SV^{r,s}\) then he does the follows. – He waits until an amount of time \(t_s \triangleq (2s - 3)\lambda + \Lambda\) has passed. – Ending Condition 0: The same instructions as Coin-Fixed-To-0 steps. – Ending Condition 1: The same instructions as Coin-Fixed-To-0 steps. – Otherwise, at the end of the wait, user \(i\) does the following. He sets \(v_i\) to be the majority vote of the \(v_j\)'s in the second components of all the valid \(m_j^{r,s-1}\)'s he has received. He computes \(b_i\) as follows. If more than \(2/3\) of all the valid \(m_j^{r,s-1}\)'s he has received are of the form \((\text{ESIG}_j(0), \text{ESIG}_j(v_j), \sigma_j^{r,s-1})\), then he sets \(b_i \triangleq 0\). Else, if more than \(2/3\) of all the valid \(m_j^{r,s-1}\)'s he has received are of the form \((\text{ESIG}_j(1), \text{ESIG}_j(v_j), \sigma_j^{r,s-1})\), then he sets \(b_i \triangleq 1\). Else, he sets \(b_i \triangleq 1\). He computes the message \(m_i^{r,s} \triangleq (\text{ESIG}_i(b_i), \text{ESIG}_i(v_i), \sigma_i^{r,s})\), destroys his ephemeral secret key \(sk_i^{r,s}\), and then propagates \(m_i^{r,s}\).
Step \(s\), \(7 \leq s \leq m + 2\), \(s - 2 \equiv 2 \bmod 3\): A Coin-Genuinely-Flipped Step of \(\text{BBA}^\star\) Instructions for every user \(i \in PK^{r-k}\): User \(i\) starts his own Step \(s\) of round \(r\) as soon as he knows \(B_{r-1}\). \(\bullet\) User \(i\) computes \(Q_{r-1}\) from the third component of \(B_{r-1}\) and checks whether \(i \in SV^{r,s}\) or not. \(\bullet\) If \(i \notin SV^{r,s}\), then \(i\) stops his own execution of Step \(s\) right away. \(\bullet\) If \(i \in SV^{r,s}\) then he does the follows. – He waits until an amount of time \(t_s \triangleq (2s - 3)\lambda + \Lambda\) has passed. – Ending Condition 0: The same instructions as Coin-Fixed-To-0 steps. – Ending Condition 1: The same instructions as Coin-Fixed-To-0 steps. – Otherwise, at the end of the wait, user \(i\) does the following. He sets \(v_i\) to be the majority vote of the \(v_j\)'s in the second components of all the valid \(m_j^{r,s-1}\)'s he has received. He computes \(b_i\) as follows. If more than \(2/3\) of all the valid \(m_j^{r,s-1}\)'s he has received are of the form \((\text{ESIG}_j(0), \text{ESIG}_j(v_j), \sigma_j^{r,s-1})\), then he sets \(b_i \triangleq 0\). Else, if more than \(2/3\) of all the valid \(m_j^{r,s-1}\)'s he has received are of the form \((\text{ESIG}_j(1), \text{ESIG}_j(v_j), \sigma_j^{r,s-1})\), then he sets \(b_i \triangleq 1\). Else, let \(SV_i^{r,s-1}\) be the set of \((r, s - 1)\)-verifiers from whom he has received a valid message \(m_j^{r,s-1}\). He sets \(b_i \triangleq \text{lsb}(\min_{j \in SV_i^{r,s-1}} H(\sigma_j^{r,s-1}))\). He computes the message \(m_i^{r,s} \triangleq (\text{ESIG}_i(b_i), \text{ESIG}_i(v_i), \sigma_i^{r,s})\), destroys his ephemeral secret key \(sk_i^{r,s}\), and then propagates \(m_i^{r,s}\).
Step \(m + 3\): The Last Step of \(\text{BBA}^\star\)a Instructions for every user \(i \in PK^{r-k}\): User \(i\) starts his own Step \(m + 3\) of round \(r\) as soon as he knows \(B_{r-1}\). \(\bullet\) User \(i\) computes \(Q_{r-1}\) from the third component of \(B_{r-1}\) and checks whether \(i \in SV^{r,m+3}\) or not. \(\bullet\) If \(i \notin SV^{r,m+3}\), then \(i\) stops his own execution of Step \(m + 3\) right away. \(\bullet\) If \(i \in SV^{r,m+3}\) then he does the follows. – He waits until an amount of time \(t_{m+3} \triangleq t_{m+2} + 2\lambda = (2m + 3)\lambda + \Lambda\) has passed. – Ending Condition 0: The same instructions as Coin-Fixed-To-0 steps. – Ending Condition 1: The same instructions as Coin-Fixed-To-0 steps. – Otherwise, at the end of the wait, user \(i\) does the following. He sets \(out_i \triangleq 1\) and \(B_r \triangleq B_\epsilon^r\). He computes the message \(m_i^{r,m+3} = (\text{ESIG}_i(out_i), \text{ESIG}_i(H(B_r)), \sigma_i^{r,m+3})\), destroys his ephemeral secret key \(sk_i^{r,m+3}\), and then propagates \(m_i^{r,m+3}\) to certify \(B_r\).b aWith overwhelming probability \(\text{BBA}^\star\) has ended before this step, and we specify this step for completeness. bA certificate from Step \(m + 3\) does not have to include \(\text{ESIG}_i(out_i)\). We include it for uniformity only: the certificates now have a uniform format no matter in which step they are generated.
Reconstruction of the Round-\(r\) Block by Non-Verifiers Instructions for every user \(i\) in the system: User \(i\) starts his own round \(r\) as soon as he knows \(B_{r-1}\), and waits for block information as follows. – If, during such waiting and at any point of time, there exists a string \(v\) and a step \(s'\) such that (a) \(5 \leq s' \leq m + 3\) with \(s' - 2 \equiv 0 \bmod 3\), (b) \(i\) has received at least \(t_H\) valid messages \(m_j^{r,s'-1} = (\text{ESIG}_j(0), \text{ESIG}_j(v), \sigma_j^{r,s'-1})\), and (c) \(i\) has received a valid message \(m_j^{r,1} = (B_j^r, esig_j(H(B_j^r)), \sigma_j^{r,1})\) with \(v = H(B_j^r)\), then, \(i\) stops his own execution of round \(r\) right away; sets \(B_r = B_j^r\); and sets his own \(\text{CERT}^r\) to be the set of messages \(m_j^{r,s'-1}\) of sub-step (b). – If, during such waiting and at any point of time, there exists a step \(s'\) such that (a') \(6 \leq s' \leq m + 3\) with \(s' - 2 \equiv 1 \bmod 3\), and (b') \(i\) has received at least \(t_H\) valid messages \(m_j^{r,s'-1} = (\text{ESIG}_j(1), \text{ESIG}_j(v_j), \sigma_j^{r,s'-1})\), then, \(i\) stops his own execution of round \(r\) right away; sets \(B_r = B_\epsilon^r\); and sets his own \(\text{CERT}^r\) to be the set of messages \(m_j^{r,s'-1}\) of sub-step (b'). – If, during such waiting and at any point of time, \(i\) has received at least \(t_H\) valid messages \(m_j^{r,m+3} = (\text{ESIG}_j(1), \text{ESIG}_j(H(B_\epsilon^r)), \sigma_j^{r,m+3})\), then \(i\) stops his own execution of round \(r\) right away, sets \(B_r = B_\epsilon^r\), and sets his own \(\text{CERT}^r\) to be the set of messages \(m_j^{r,m+3}\) for 1 and \(H(B_\epsilon^r)\). 5.5 Analysis of \(\text{Algorand}'_1\) We introduce the following notations for each round \(r \geq 0\), used in the analysis. \(\bullet\) Let \(T^r\) be the time when the first honest user knows \(B_{r-1}\). \(\bullet\) Let \(I^{r+1}\) be the interval \([T^{r+1}, T^{r+1} + \lambda]\). Note that \(T^0 = 0\) by the initialization of the protocol. For each \(s \geq 1\) and \(i \in SV^{r,s}\), recall that \(\alpha_i^{r,s}\)
and \(\beta_i^{r,s}\) are respectively the starting time and the ending time of player \(i\)'s step \(s\). Moreover, recall that \(t_s = (2s - 3)\lambda + \Lambda\) for each \(2 \leq s \leq m + 3\). In addition, let \(I_0 \triangleq \{0\}\) and \(t_1 \triangleq 0\). Finally, recall that \(L_r \leq m/3\) is a random variable representing the number of Bernoulli trials needed to see a 1, when each trial is 1 with probability \(\frac{p_h}{2}\) and there are at most \(m/3\) trials. If all trials fail then \(L_r \triangleq m/3\). In the analysis we ignore computation time, as it is in fact negligible relative to the time needed to propagate messages. In any case, by using slightly larger \(\lambda\) and \(\Lambda\), the computation time can be incorporated into the analysis directly. Most of the statements below hold “with overwhelming probability,” and we may not repeatedly emphasize this fact in the analysis.
5.6 Main Theorem Theorem 5.1. The following properties hold with overwhelming probability for each round \(r \geq 0\): 1. All honest users agree on the same block \(B_r\). 2. When the leader \(\ell_r\) is honest, the block \(B_r\) is generated by \(\ell_r\), \(B_r\) contains a maximal payset received by \(\ell_r\) by time \(\alpha_{\ell_r}^{r,1}\), \(T^{r+1} \leq T^r + 8\lambda + \Lambda\) and all honest users know \(B_r\) in the time interval \(I_{r+1}\). 3. When the leader \(\ell_r\) is malicious, \(T^{r+1} \leq T^r + (6L_r + 10)\lambda + \Lambda\) and all honest users know \(B_r\) in the time interval \(I_{r+1}\). 4. \(p_h = h^2(1 + h - h^2)\) for \(L_r\), and the leader \(\ell_r\) is honest with probability at least \(p_h\). Before proving our main theorem, let us make two remarks. Remarks. • Block-Generation and True Latency. The time to generate block \(B_r\) is defined to be \(T^{r+1} - T^r\). That is, it is defined to be the difference between the first time some honest user learns \(B_r\) and the first time some honest user learns \(B_{r-1}\). When the round-\(r\) leader is honest, Property 2 our main theorem guarantees that the exact time to generate \(B_r\) is \(8\lambda + \Lambda\) time, no matter what the precise value of \(h > 2/3\) may be. When the leader is malicious, Property 3 implies that the expected time to generate \(B_r\) is upperbounded by \((\frac{12}{p_h} + 10)\lambda + \Lambda\), again no matter the precise value of \(h\).18 However, the expected time to generate \(B_r\) depends on the precise value of \(h\). Indeed, by Property 4, \(p_h = h^2(1 + h - h^2)\) and the leader is honest with probability at least \(p_h\), thus \(E[T^{r+1} - T^r] \leq h^2(1 + h - h^2) \cdot (8\lambda + \Lambda) + (1 - h^2(1 + h - h^2))((\frac{12}{h^2(1 + h - h^2)} + 10)\lambda + \Lambda)\). For instance, if \(h = 80\%\), then \(E[T^{r+1} - T^r] \leq 12.7\lambda + \Lambda\). • \(\lambda\) vs. \(\Lambda\). Note that the size of the messages sent by the verifiers in a step \(\text{Algorand}^\prime\) is dominated by the length of the digital signature keys, which can remain fixed, even when the number of users is enormous. Also note that, in any step \(s > 1\), the same expected number \(n\) of verifiers can be used whether the number of users is 100K, 100M, or 100M. This is so because \(n\) solely depends on \(h\) and \(F\). In sum, therefore, barring a sudden need to increase secret key length, the value of \(\lambda\) should remain the same no matter how large the number of users may be in the foreseeable future. By contrast, for any transaction rate, the number of transactions grows with the number of users. Therefore, to process all new transactions in a timely fashion, the size of a block should also grow with the number of users, causing \(\Lambda\) to grow too. Thus, in the long run, we should have \(\lambda \ll \Lambda\). Accordingly, it is proper to have a larger coefficient for \(\lambda\), and actually a coefficient of 1 for \(\Lambda\). Proof of Theorem 5.1. We prove Properties 1–3 by induction: assuming they hold for round \(r - 1\) (without loss of generality, they automatically hold for "round -1" when \(r = 0\)), we prove them for round \(r\). 18Indeed, \(E[T^{r+1} - T^r] \leq (6E[L_r] + 10)\lambda + \Lambda = (6 \cdot \frac{2}{p_h} + 10)\lambda + \Lambda = (\frac{12}{p_h} + 10)\lambda + \Lambda\).
Since \(B_{r-1}\) is uniquely defined by the inductive hypothesis, the set \(SV^{r,s}\) is uniquely defined for each step \(s\) of round \(r\). By the choice of \(n_1\), \(SV^{r,1} \neq \emptyset\) with overwhelming probability. We now state the following two lemmas, proved in Sections 5.7 and 5.8. Throughout the induction and in the proofs of the two lemmas, the analysis for round 0 is almost the same as the inductive step, and we will highlight the differences when they occur. Lemma 5.2. [Completeness Lemma] Assuming Properties 1–3 hold for round \(r-1\), when the leader \(\ell_r\) is honest, with overwhelming probability, • All honest users agree on the same block \(B_r\), which is generated by \(\ell_r\) and contains a maximal payset received by \(\ell_r\) by time \(\alpha_{\ell_r}^{r,1} \in I_r\); and • \(T^{r+1} \leq T^r + 8\lambda + \Lambda\) and all honest users know \(B_r\) in the time interval \(I_{r+1}\). Lemma 5.3. [Soundness Lemma] Assuming Properties 1–3 hold for round \(r - 1\), when the leader \(\ell_r\) is malicious, with overwhelming probability, all honest users agree on the same block \(B_r\), \(T^{r+1} \leq T^r + (6L_r + 10)\lambda + \Lambda\) and all honest users know \(B_r\) in the time interval \(I_{r+1}\). Properties 1–3 hold by applying Lemmas 5.2 and 5.3 to r = 0 and to the inductive step. Finally, we restate Property 4 as the following lemma, proved in Section 5.9. Lemma 5.4. Given Properties 1–3 for each round before \(r\), \(p_h = h^2(1 + h - h^2)\) for \(L_r\), and the leader \(\ell_r\) is honest with probability at least \(p_h\). Combining the above three lemmas together, Theorem 5.1 holds. ■ The lemma below states several important properties about round \(r\) given the inductive hypothesis, and will be used in the proofs of the above three lemmas. Lemma 5.5. Assume Properties 1–3 hold for round \(r - 1\). For each step \(s \geq 1\) of round \(r\) and each honest verifier \(i \in HSV^{r,s}\), we have that (a) \(\alpha_i^{r,s} \in I_r\); (b) if player \(i\) has waited an amount of time \(t_s\), then \(\beta_i^{r,s} \in [T^r + t_s, T^r + \lambda + t_s]\) for \(r > 0\) and \(\beta_i^{r,s} = t_s\) for \(r = 0\); and (c) if player \(i\) has waited an amount of time \(t_s\), then by time \(\beta_i^{r,s}\), he has received all messages sent by all honest verifiers \(j \in HSV^{r,s'}\) for all steps \(s' < s\). Moreover, for each step \(s \geq 3\), we have that (d) there do not exist two different players \(i, i' \in SV^{r,s}\) and two different values \(v, v'\) of the same length, such that both players have waited an amount of time \(t_s\), more than 2/3 of all the valid messages \(m_j^{r,s-1}\) player \(i\) receives have signed for \(v\), and more than 2/3 of all the valid messages \(m_j^{r,s-1}\) player \(i'\) receives have signed for \(v'\). Proof. Property (a) follows directly from the inductive hypothesis, as player \(i\) knows \(B_{r-1}\) in the time interval \(I_r\) and starts his own step \(s\) right away. Property (b) follows directly from (a): since player \(i\) has waited an amount of time \(t_s\) before acting, \(\beta_i^{r,s} = \alpha_i^{r,s} + t_s\). Note that \(\alpha_i^{r,s} = 0\) for \(r = 0\). We now prove Property (c). If \(s = 2\), then by Property (b), for all verifiers \(j \in HSV^{r,1}\) we have \(\beta_i^{r,s} = \alpha_i^{r,s} + t_s \geq T^r + t_s = T^r + \lambda + \Lambda \geq \beta_j^{r,1} + \Lambda\).
Since each verifier \(j \in HSV^{r,1}\) sends his message at time \(\beta_j^{r,1}\) and the message reaches all honest users in at most \(\Lambda\) time, by time \(\beta_i^{r,s}\) player \(i\) has received the messages sent by all verifiers in \(HSV^{r,1}\) as desired. If \(s > 2\), then \(t_s = t_{s-1} + 2\lambda\). By Property (b), for all steps \(s' < s\) and all verifiers \(j \in HSV^{r,s'}\), \(\beta_i^{r,s} = \alpha_i^{r,s} + t_s \geq T^r + t_s = T^r + t_{s-1} + 2\lambda \geq T^r + t_{s'} + 2\lambda = T^r + \lambda + t_{s'} + \lambda \geq \beta_j^{r,s'} + \lambda\). Since each verifier \(j \in HSV^{r,s'}\) sends his message at time \(\beta_j^{r,s'}\) and the message reaches all honest users in at most \(\lambda\) time, by time \(\beta_i^{r,s}\) player \(i\) has received all messages sent by all honest verifiers in \(HSV^{r,s'}\) for all \(s' < s\). Thus Property (c) holds. Finally, we prove Property (d). Note that the verifiers \(j \in SV^{r,s-1}\) sign at most two things in Step \(s - 1\) using their ephemeral secret keys: a value \(v_j\) of the same length as the output of the hash function, and also a bit \(b_j \in \{0, 1\}\) if \(s - 1 \geq 4\). That is why in the statement of the lemma we require that \(v\) and \(v'\) have the same length: many verifiers may have signed both a hash value \(v\) and a bit \(b\), thus both pass the 2/3 threshold. Assume for the sake of contradiction that there exist the desired verifiers \(i, i'\) and values \(v, v'\). Note that some malicious verifiers in \(MSV^{r,s-1}\) may have signed both \(v\) and \(v'\), but each honest verifier in \(HSV^{r,s-1}\) has signed at most one of them. By Property (c), both \(i\) and \(i'\) have received all messages sent by all honest verifiers in \(HSV^{r,s-1}\). Let \(HSV^{r,s-1}(v)\) be the set of honest \((r, s - 1)\)-verifiers who have signed \(v\), \(MSV_i^{r,s-1}\) the set of malicious \((r, s - 1)\)-verifiers from whom \(i\) has received a valid message, and \(MSV_i^{r,s-1}(v)\) the subset of \(MSV_i^{r,s-1}\) from whom \(i\) has received a valid message signing \(v\). By the requirements for \(i\) and \(v\), we have \(\text{ratio} \triangleq \frac{|HSV^{r,s-1}(v)| + |MSV_i^{r,s-1}(v)|}{|HSV^{r,s-1}| + |MSV_i^{r,s-1}|} > \frac{2}{3}\). (1) We first show \(|MSV_i^{r,s-1}(v)| \leq |HSV^{r,s-1}(v)|\). (2) Assuming otherwise, by the relationships among the parameters, with overwhelming probability \(|HSV^{r,s-1}| > 2|MSV^{r,s-1}| \geq 2|MSV_i^{r,s-1}|\), thus \(\text{ratio} < \frac{|HSV^{r,s-1}(v)| + |MSV_i^{r,s-1}(v)|}{3|MSV_i^{r,s-1}|} < \frac{2|MSV_i^{r,s-1}(v)|}{3|MSV_i^{r,s-1}|} \leq \frac{2}{3},\) contradicting Inequality 1. Next, by Inequality 1 we have \(2|HSV^{r,s-1}| + 2|MSV_i^{r,s-1}| < 3|HSV^{r,s-1}(v)| + 3|MSV_i^{r,s-1}(v)| \leq 3|HSV^{r,s-1}(v)| + 2|MSV_i^{r,s-1}| + |MSV_i^{r,s-1}(v)|.\) Combining with Inequality 2, \(2|HSV^{r,s-1}| < 3|HSV^{r,s-1}(v)| + |MSV_i^{r,s-1}(v)| \leq 4|HSV^{r,s-1}(v)|,\) which implies \(|HSV^{r,s-1}(v)| > \frac{1}{2}|HSV^{r,s-1}|.\)
Similarly, by the requirements for \(i'\) and \(v'\), we have \(|HSV^{r,s-1}(v')| > \frac{1}{2}|HSV^{r,s-1}|.\) Since an honest verifier \(j \in HSV^{r,s-1}\) destroys his ephemeral secret key \(sk_j^{r,s-1}\) before propagating his message, the Adversary cannot forge \(j\)'s signature for a value that \(j\) did not sign, after learning that \(j\) is a verifier. Thus, the two inequalities above imply \(|HSV^{r,s-1}| \geq |HSV^{r,s-1}(v)| +\) \(|HSV^{r,s-1}(v')| > |HSV^{r,s-1}|\), a contradiction. Accordingly, the desired \(i, i', v, v'\) do not exist, and Property (d) holds. ■ 5.7 The Completeness Lemma Lemma 5.2. [Completeness Lemma, restated] Assuming Properties 1–3 hold for round \(r-1\), when the leader \(\ell_r\) is honest, with overwhelming probability, - All honest users agree on the same block \(B_r\), which is generated by \(\ell_r\) and contains a maximal payset received by \(\ell_r\) by time \(\alpha_{\ell_r}^{r,1} \in I_r\); and - \(T^{r+1} \leq T^r + 8\lambda + \Lambda\) and all honest users know \(B_r\) in the time interval \(I_{r+1}\). Proof. By the inductive hypothesis and Lemma 5.5, for each step \(s\) and verifier \(i \in HSV^{r,s}\), \(\alpha_i^{r,s} \in I_r\). Below we analyze the protocol step by step. Step 1. By definition, every honest verifier \(i \in HSV^{r,1}\) propagates the desired message \(m_i^{r,1}\) at time \(\beta_i^{r,1} = \alpha_i^{r,1}\), where \(m_i^{r,1} = (B_i^r, \text{esig}_i(H(B_i^r)), \sigma_i^{r,1})\), \(B_i^r = (r, PAY_i^r, \text{SIG}_i(Q_{r-1}), H(B_{r-1}))\), and \(PAY_i^r\) is a maximal payset among all payments that \(i\) has seen by time \(\alpha_i^{r,1}\). Step 2. Arbitrarily fix an honest verifier \(i \in HSV^{r,2}\). By Lemma 5.5, when player \(i\) is done waiting at time \(\beta_i^{r,2} = \alpha_i^{r,2} + t_2\), he has received all messages sent by verifiers in \(HSV^{r,1}\), including \(m_{\ell_r}^{r,1}\). By the definition of \(\ell_r\), there does not exist another player in \(PK^{r-k}\) whose credential's hash value is smaller than \(H(\sigma_{\ell_r}^{r,1})\). Of course, the Adversary can corrupt \(\ell_r\) after seeing that \(H(\sigma_{\ell_r}^{r,1})\) is very small, but by that time player \(\ell_r\) has destroyed his ephemeral key and the message \(m_{\ell_r}^{r,1}\) has been propagated. Thus verifier \(i\) sets his own leader to be player \(\ell_r\). Accordingly, at time \(\beta_i^{r,2}\), verifier \(i\) propagates \(m_i^{r,2} = (\text{ESIG}_i(v'_i), \sigma_i^{r,2})\), where \(v'_i = H(B_{\ell_r}^r)\). When \(r = 0\), the only difference is that \(\beta_i^{r,2} = t_2\) rather than being in a range. Similar things can be said for future steps and we will not emphasize them again. Step 3. Arbitrarily fix an honest verifier \(i \in HSV^{r,3}\). By Lemma 5.5, when player \(i\) is done waiting at time \(\beta_i^{r,3} = \alpha_i^{r,3} + t_3\), he has received all messages sent by verifiers in \(HSV^{r,2}\). By the relationships among the parameters, with overwhelming probability \(|HSV^{r,2}| >\) \(2|MSV^{r,2}|\). Moreover, no honest verifier would sign contradicting messages, and the Adversary cannot forge a signature of an honest verifier after the latter has destroyed his corresponding ephemeral secret key. Thus more than 2/3 of all the valid \((r, 2)\)-messages \(i\) has received are from honest verifiers and of the form \(m_j^{r,2} = (\text{ESIG}_j(H(B_{\ell_r}^r)), \sigma_j^{r,2})\), with no contradiction. Accordingly, at time \(\beta_i^{r,3}\) player \(i\) propagates \(m_i^{r,3} = (\text{ESIG}_i(v'), \sigma_i^{r,3})\), where \(v' = H(B_{\ell_r}^r)\).
Step 4. Arbitrarily fix an honest verifier \(i \in HSV^{r,4}\). By Lemma 5.5, player \(i\) has received all messages sent by verifiers in \(HSV^{r,3}\) when he is done waiting at time \(\beta_i^{r,4} = \alpha_i^{r,4} + t_4\). Similar to Step 3, more than 2/3 of all the valid \((r, 3)\)-messages \(i\) has received are from honest verifiers and of the form \(m_j^{r,3} = (\text{ESIG}_j(H(B_{\ell_r}^r)), \sigma_j^{r,3})\). Accordingly, player \(i\) sets \(v_i = H(B_{\ell_r}^r)\), \(g_i = 2\) and \(b_i = 0\). At time \(\beta_i^{r,4} = \alpha_i^{r,4} + t_4\) he propagates \(m_i^{r,4} = (\text{ESIG}_i(0), \text{ESIG}_i(H(B_{\ell_r}^r)), \sigma_i^{r,4})\). Step 5. Arbitrarily fix an honest verifier \(i \in HSV^{r,5}\). By Lemma 5.5, player \(i\) would have received all messages sent by the verifiers in \(HSV^{r,4}\) if he has waited till time \(\alpha_i^{r,5} + t_5\). Note that \(|HSV^{r,4}| \geq t_H\).19 Also note that all verifiers in \(HSV^{r,4}\) have signed for \(H(B_{\ell_r}^r)\). As \(|MSV^{r,4}| < t_H\), there does not exist any \(v' \neq H(B_{\ell_r}^r)\) that could have been signed by \(t_H\) verifiers in \(SV^{r,4}\) (who would necessarily be malicious), so player \(i\) does not stop before he has received \(t_H\) valid messages \(m_j^{r,4} = (\text{ESIG}_j(0), \text{ESIG}_j(H(B_{\ell_r}^r)), \sigma_j^{r,4})\). Let \(T\) be the time when the latter event happens. Some of those messages may be from malicious players, but because \(|MSV^{r,4}| < t_H\), at least one of them is from an honest verifier in \(HSV^{r,4}\) and is sent after time \(T^r + t_4\). Accordingly, \(T \geq T^r + t_4 > T^r + \lambda + \Lambda \geq \beta_{\ell_r}^{r,1} + \Lambda\), and by time \(T\) player \(i\) has also received the message \(m_{\ell_r}^{r,1}\). By the construction of the protocol, player \(i\) stops at time \(\beta_i^{r,5} = T\) without propagating anything; sets \(B_r = B_{\ell_r}^r\); and sets his own \(\text{CERT}^r\) to be the set of \((r, 4)\)-messages for 0 and \(H(B_{\ell_r}^r)\) that he has received. Step \(s > 5\). Similarly, for any step \(s > 5\) and any verifier \(i \in HSV^{r,s}\), player \(i\) would have received all messages sent by the verifiers in \(HSV^{r,4}\) if he has waited till time \(\alpha_i^{r,s} + t_s\). By the same analysis, player \(i\) stops without propagating anything, setting \(B_r = B_{\ell_r}^r\) (and setting his own \(\text{CERT}^r\) properly). Of course, the malicious verifiers may not stop and may propagate arbitrary messages, but because \(|MSV^{r,s}| < t_H\), by induction no other \(v'\) could be signed by \(t_H\) verifiers in any step \(4 \leq s' < s\), thus the honest verifiers only stop because they have received \(t_H\) valid \((r, 4)\)-messages for 0 and \(H(B_{\ell_r}^r)\). Reconstruction of the Round-\(r\) Block. The analysis of Step 5 applies to a generic honest user \(i\) almost without any change. Indeed, player \(i\) starts his own round \(r\) in the interval \(I_r\) and will only stop at a time \(T\) when he has received \(t_H\) valid \((r, 4)\)-messages for \(H(B_{\ell_r}^r)\). Again because at least one of those messages are from honest verifiers and are sent after time \(T^r + t_4\), player \(i\) has also received \(m_{\ell_r}^{r,1}\) by time \(T\). Thus he sets \(B_r = B_{\ell_r}^r\) with the proper \(\text{CERT}^r\). It only remains to show that all honest users finish their round \(r\) within the time interval \(I_{r+1}\). By the analysis of Step 5, every honest verifier \(i \in HSV^{r,5}\) knows \(B_r\) on or before \(\alpha_i^{r,5} + t_5 \leq\) \(T^r + \lambda + t_5 = T^r + 8\lambda + \Lambda\). Since \(T^{r+1}\) is the time when the first honest user \(i_r\) knows \(B_r\), we have \(T^{r+1} \leq T^r + 8\lambda + \Lambda\) as desired. Moreover, when player \(i_r\) knows \(B_r\), he has already helped propagating the messages in his \(\text{CERT}^r\). Note that all those messages will be received by all honest users within time \(\lambda\), even if 19Strictly speaking, this happens with very high probability but not necessarily overwhelming. However, this probability slightly effects the running time of the protocol, but does not affect its correctness. When \(h = 80\%\), then \(|HSV^{r,4}| \geq t_H\) with probability \(1 - 10^{-8}\). If this event does not occur, then the protocol will continue for another 3 steps. As the probability that this does not occur in two steps is negligible, the protocol will finish at Step 8. In expectation, then, the number of steps needed is almost 5.
player \(i_r\) were the first player to propagate them. Moreover, following the analysis above we have \(T^{r+1} \geq T^r + t_4 \geq \beta_{\ell_r}^{r,1} + \Lambda\), thus all honest users have received \(m_{\ell_r}^{r,1}\) by time \(T^{r+1} + \lambda\). Accordingly, all honest users know \(B_r\) in the time interval \(I_{r+1} = [T^{r+1}, T^{r+1} + \lambda]\). Finally, for \(r = 0\) we actually have \(T^1 \leq t_4 + \lambda = 6\lambda + \Lambda\). Combining everything together, Lemma 5.2 holds. ■ 5.8 The Soundness Lemma Lemma 5.3. [Soundness Lemma, restated] Assuming Properties 1–3 hold for round \(r - 1\), when the leader \(\ell_r\) is malicious, with overwhelming probability, all honest users agree on the same block \(B_r\), \(T^{r+1} \leq T^r + (6L_r + 10)\lambda + \Lambda\) and all honest users know \(B_r\) in the time interval \(I_{r+1}\). Proof. We consider the two parts of the protocol, GC and \(\text{BBA}^\star\), separately. GC. By the inductive hypothesis and by Lemma 5.5, for any step \(s \in \{2, 3, 4\}\) and any honest verifier \(i \in HSV^{r,s}\), when player \(i\) acts at time \(\beta_i^{r,s} = \alpha_i^{r,s} + t_s\), he has received all messages sent by all the honest verifiers in steps \(s' < s\). We distinguish two possible cases for step 4. Case 1. No verifier \(i \in HSV^{r,4}\) sets \(g_i = 2\). In this case, by definition \(b_i = 1\) for all verifiers \(i \in HSV^{r,4}\). That is, they start with an agreement on 1 in the binary BA protocol. They may not have an agreement on their \(v_i\)'s, but this does not matter as we will see in the binary BA. Case 2. There exists a verifier \(\hat{i} \in HSV^{r,4}\) such that \(g_{\hat{i}} = 2\). In this case, we show that (1) \(g_i \geq 1\) for all \(i \in HSV^{r,4}\), (2) there exists a value \(v'\) such that \(v_i = v'\) for all \(i \in HSV^{r,4}\), and (3) there exists a valid message \(m_\ell^{r,1}\) from some verifier \(\ell \in SV^{r,1}\) such that \(v' = H(B_\ell^r)\). Indeed, since player \(\hat{i}\) is honest and sets \(g_{\hat{i}} = 2\), more than 2/3 of all the valid messages \(m_j^{r,3}\) he has received are for the same value \(v' \neq \bot\), and he has set \(v_{\hat{i}} = v'\). By Property (d) in Lemma 5.5, for any other honest \((r, 4)\)-verifier \(i\), it cannot be that more than 2/3 of all the valid messages \(m_j^{r,3}\) that \(i'\) has received are for the same value \(v'' \neq v'\). Accordingly, if \(i\) sets \(g_i = 2\), it must be that \(i\) has seen > 2/3 majority for \(v'\) as well and set \(v_i = v'\), as desired. Now consider an arbitrary verifier \(i \in HSV^{r,4}\) with \(g_i < 2\). Similar to the analysis of Property (d) in Lemma 5.5, because player \(\hat{i}\) has seen > 2/3 majority for \(v'\), more than \(\frac{1}{2}|HSV^{r,3}|\) honest \((r, 3)\)-verifiers have signed \(v'\). Because \(i\) has received all messages by honest \((r, 3)\)-verifiers by time \(\beta_i^{r,4} = \alpha_i^{r,4} + t_4\), he has in particular received more than \(\frac{1}{2}|HSV^{r,3}|\) messages from them for \(v'\). Because \(|HSV^{r,3}| > 2|MSV^{r,3}|\), \(i\) has seen > 1/3 majority for \(v'\). Accordingly, player \(i\) sets \(g_i = 1\), and Property (1) holds. Does player \(i\) necessarily set \(v_i = v'\)? Assume there exists a different value \(v'' \neq \bot\) such that player \(i\) has also seen > 1/3 majority for \(v''\). Some of those messages may be from malicious verifiers, but at least one of them is from some honest verifier \(j \in HSV^{r,3}\): indeed, because \(|HSV^{r,3}| > 2|MSV^{r,3}|\) and \(i\) has received all messages from \(HSV^{r,3}\), the set of malicious verifiers from whom \(i\) has received a valid \((r, 3)\)-message counts for < 1/3 of all the valid messages he has received.
By definition, player j must have seen > 2/3 majority for \(v''\) among all the valid (r, 2)-messages he has received. However, we already have that some other honest (r, 3)-verifiers have seen
2/3 majority for \(v'\) (because they signed \(v'\)). By Property (d) of Lemma 5.5, this cannot happen and such a value \(v''\) does not exist. Thus player i must have set \(v_i = v'\) as desired, and Property (2) holds. Finally, given that some honest (r, 3)-verifiers have seen > 2/3 majority for \(v'\), some (actually, more than half of) honest (r, 2)-verifiers have signed for \(v'\) and propagated their messages. By the construction of the protocol, those honest (r, 2)-verifiers must have received a valid message \(m_\ell^{r,1}\) from some player \(\ell \in SV^{r,1}\) with \(v'\) = \(H(B_\ell^r)\), thus Property (3) holds. \(\text{BBA}^\star\). We again distinguish two cases. Case 1. All verifiers \(i \in HSV^{r,4}\) have \(b_i = 1\). This happens following Case 1 of GC. As \(|MSV^{r,4}|\) < \(t_H\), in this case no verifier in \(SV^{r,5}\) could collect or generate \(t_H\) valid (r, 4)-messages for bit 0. Thus, no honest verifier in \(HSV^{r,5}\) would stop because he knows a non-empty block \(B_r\). Moreover, although there are at least \(t_H\) valid \((r, 4)\)-messages for bit 1, \(s' = 5\) does not satisfy \(s' - 2 \equiv 1 \mod 3\), thus no honest verifier in \(HSV^{r,5}\) would stop because he knows \(B_r = B_\epsilon^r\). Instead, every verifier \(i \in HSV^{r,5}\) acts at time \(\beta_i^{r,5} = \alpha_i^{r,5} + t_5\), by when he has received all messages sent by \(HSV^{r,4}\) following Lemma 5.5. Thus player \(i\) has seen > 2/3 majority for 1 and sets \(b_i = 1\). In Step 6 which is a Coin-Fixed-To-1 step, although \(s' = 5\) satisfies \(s' - 2 \equiv 0 \mod 3\), there do not exist \(t_H\) valid \((r, 4)\)-messages for bit 0, thus no verifier in \(HSV^{r,6}\) would stop because he knows a non-empty block \(B_r\). However, with \(s' = 6\), \(s' - 2 \equiv 1 \mod 3\) and there do exist \(|HSV^{r,5}| \geq t_H\) valid \((r, 5)\)-messages for bit 1 from \(HSV^{r,5}\). For every verifier \(i \in HSV^{r,6}\), following Lemma 5.5, on or before time \(\alpha_i^{r,6} + t_6\) player \(i\) has received all messages from \(HSV^{r,5}\), thus \(i\) stops without propagating anything and sets \(B_r = B_\epsilon^r\). His \(\text{CERT}^r\) is the set of \(t_H\) valid \((r, 5)\)-messages \(m_j^{r,5} = (\text{ESIG}_j(1), \text{ESIG}_j(v_j), \sigma_j^{r,5})\) received by him when he stops. Next, let player \(i\) be either an honest verifier in a step \(s > 6\) or a generic honest user (i.e., non-verifier). Similar to the proof of Lemma 5.2, player \(i\) sets \(B_r = B_\epsilon^r\) and sets his own \(\text{CERT}^r\) to be the set of \(t_H\) valid \((r, 5)\)-messages \(m_j^{r,5} = (\text{ESIG}_j(1), \text{ESIG}_j(v_j), \sigma_j^{r,5})\) he has received. Finally, similar to Lemma 5.2, \(T^{r+1} \leq \min_{i \in HSV^{r,6}} \alpha_i^{r,6} + t_6 \leq T^r + \lambda + t_6 = T^r + 10\lambda + \Lambda,\) and all honest users know \(B_r\) in the time interval \(I_{r+1}\), because the first honest user \(i\) who knows \(B_r\) has helped propagating the \((r, 5)\)-messages in his \(\text{CERT}^r\). Case 2. There exists a verifier \(\hat{i} \in HSV^{r,4}\) with \(b_{\hat{i}} = 0\). This happens following Case 2 of GC and is the more complex case. By the analysis of GC, in this case there exists a valid message \(m_\ell^{r,1}\) such that \(v_i = H(B_\ell^r)\) for all \(i \in HSV^{r,4}\). Note that the verifiers in \(HSV^{r,4}\) may not have an agreement on their \(b_i\)'s. For any step \(s \in \{5, \ldots, m + 3\}\) and verifier \(i \in HSV^{r,s}\), by Lemma 5.5 player \(i\) would have received all messages sent by all honest verifiers in \(HSV^{r,4} \cup \cdots \cup HSV^{r,s-1}\) if he has waited for time \(t_s\).
We now consider the following event E: there exists a step \(s^* \geq 5\) such that, for the first time in the binary BA, some player \(i^* \in SV^{r,s^*}\) (whether malicious or honest) should stop without propagating anything. We use "should stop" to emphasize the fact that, if player \(i^*\) is malicious, then he may pretend that he should not stop according to the protocol and propagate messages of the Adversary's choice. Moreover, by the construction of the protocol, either (E.a) \(i^*\) is able to collect or generate at least \(t_H\) valid messages \(m_j^{r,s'-1} = (\text{ESIG}_j(0), \text{ESIG}_j(v), \sigma_j^{r,s'-1})\) for the same \(v\) and \(s'\), with \(5 \leq s' \leq s^*\) and \(s' - 2 \equiv 0 \mod 3\); or (E.b) \(i^*\) is able to collect or generate at least \(t_H\) valid messages \(m_j^{r,s'-1} = (\text{ESIG}_j(1), \text{ESIG}_j(v_j), \sigma_j^{r,s'-1})\) for the same \(s'\), with \(6 \leq s' \leq s^*\) and \(s' - 2 \equiv 1 \mod 3\). Because the honest \((r, s' - 1)\)-messages are received by all honest \((r, s')\)-verifiers before they are done waiting in Step \(s'\), and because the Adversary receives everything no later than the honest users, without loss of generality we have \(s' = s^*\) and player \(i^*\) is malicious. Note that we did not require the value v in E.a to be the hash of a valid block: as it will become clear in the analysis, v = \(H(B_\ell^r)\) in this sub-event. Below we first analyze Case 2 following event E, and then show that the value of \(s^*\) is essentially distributed accordingly to \(L_r\) (thus event E happens before Step m + 3 with overwhelming probability given the relationships for parameters). To begin with, for any step \(5 \leq s < s^*\), every honest verifier \(i \in HSV^{r,s}\) has waited time \(t_s\) and set \(v_i\) to be the majority vote of the valid \((r, s-1)\)-messages he has received. Since player \(i\) has received all honest \((r, s-1)\)-messages following Lemma 5.5, since all honest verifiers in \(HSV^{r,4}\) have signed \(H(B_\ell^r)\) following Case 2 of GC, and since \(|HSV^{r,s-1}| > 2|MSV^{r,s-1}|\) for each \(s\), by induction we have that player \(i\) has set \(v_i = H(B_\ell^r)\). The same holds for every honest verifier \(i \in HSV^{r,s^*}\) who does not stop without propagating anything. Now we consider Step \(s^*\) and distinguish four subcases. Case 2.1.a. Event E.a happens and there exists an honest verifier \(i' \in HSV^{r,s^*}\) who should also stop without propagating anything. In this case, we have \(s^* - 2 \equiv 0 \mod 3\) and Step \(s^*\) is a Coin-Fixed-To-0 step. By definition, player \(i'\) has received at least \(t_H\) valid (r, \(s^* - 1\))-messages of the form \((\text{ESIG}_j(0), \text{ESIG}_j(v), \sigma_j^{r,s^*-1})\). Since all verifiers in \(HSV^{r,s^*-1}\) have signed \(H(B_\ell^r)\) and \(|MSV^{r,s^*-1}| < t_H\), we have v = \(H(B_\ell^r)\). Since at least \(t_H - |MSV^{r,s^*-1}| \geq 1\) of the (r, \(s^* - 1\))-messages received by \(i'\) for 0 and v are sent by verifiers in \(HSV^{r,s^*-1}\) after time \(T^r + t_{s^*-1} \geq T^r + t_4 \geq T^r + \lambda + \Lambda \geq \beta_{\ell}^{r,1} + \Lambda\), player \(i'\) has received \(m_\ell^{r,1}\) by the time he receives those (r, \(s^* - 1\))-messages. Thus player \(i'\) stops without propagating anything; sets \(B_r = B_\ell^r\); and sets his own \(\text{CERT}^r\) to be the set of valid (r, \(s^* - 1\))-messages for 0 and v that he has received. Next, we show that, any other verifier \(i \in HSV^{r,s^*}\) has either stopped with \(B_r = B_\ell^r\), or has set \(b_i = 0\) and propagated \((\text{ESIG}_i(0), \text{ESIG}_i(H(B_\ell^r)), \sigma_i^{r,s^*})\). Indeed, because Step \(s^*\) is the first time some verifier should stop without propagating anything, there does not exist a step \(s' < s^*\) with \(s' - 2 \equiv 1 \mod 3\) such that \(t_H\) \((r, s' - 1)\)-verifiers have signed 1. Accordingly, no verifier in \(HSV^{r,s^*}\) stops with \(B_r = B_\epsilon^r\).
Moreover, as all honest verifiers in steps {4, 5, . . . , \(s^* - 1\)} have signed \(H(B_\ell^r)\), there does not exist a step \(s' \leq s^*\) with \(s' - 2 \equiv 0 \mod 3\) such that \(t_H\) \((r, s' - 1)\)-verifiers have signed some \(v'' \neq H(B_\ell^r)\) —indeed, \(|MSV^{r,s'-1}| < t_H\). Accordingly, no verifier in \(HSV^{r,s^*}\) stops with \(B_r \neq B_\epsilon^r\) and \(B_r \neq B_\ell^r\). That is, if a player \(i \in HSV^{r,s^*}\) has stopped without propagating anything, he must have set \(B_r = B_\ell^r\). If a player \(i \in HSV^{r,s^*}\) has waited time \(t_{s^*}\) and propagated a message at time \(\beta_i^{r,s^*} = \alpha_i^{r,s^*} + t_{s^*}\), he has received all messages from \(HSV^{r,s^*-1}\), including at least \(t_H - |MSV^{r,s^*-1}|\) of them for 0 and v. If i has seen > 2/3 majority for 1, then he has seen more than \(2(t_H - |MSV^{r,s^*-1}|)\) valid (r, \(s^* - 1\))-messages for 1, with more than \(2t_H - 3|MSV^{r,s^*-1}|\) of them from honest (r, \(s^* - 1\))-verifiers. However, this implies \(|HSV^{r,s^*-1}| \geq t_H - |MSV^{r,s^*-1}| + 2t_H - 3|MSV^{r,s^*-1}| > 2n - 4|MSV^{r,s^*-1}|\), contradicting the fact that \(|HSV^{r,s^*-1}| + 4|MSV^{r,s^*-1}| < 2n\), which comes from the relationships for the parameters. Accordingly, i does not see > 2/3 majority for 1, and he sets \(b_i = 0\) because Step \(s^*\) is a Coin-Fixed-To-0 step. As we have seen, \(v_i = H(B_\ell^r)\). Thus i propagates \((\text{ESIG}_i(0), \text{ESIG}_i(H(B_\ell^r)), \sigma_i^{r,s^*})\) as we wanted to show. For Step \(s^* + 1\), since player \(i'\) has helped propagating the messages in his \(\text{CERT}^r\) on or before time \(\alpha_{i'}^{r,s^*} + t_{s^*}\), all honest verifiers in \(HSV^{r,s^*+1}\) have received at least \(t_H\) valid (r, \(s^* - 1\))-messages for bit 0 and value \(H(B_\ell^r)\) on or before they are done waiting. Furthermore, verifiers in \(HSV^{r,s^*+1}\) will not stop before receiving those (r, \(s^* - 1\))- messages, because there do not exist any other \(t_H\) valid \((r, s' - 1)\)-messages for bit 1 with \(s' - 2 \equiv 1 \mod 3\) and \(6 \leq s' \leq s^* + 1\), by the definition of Step \(s^*\). In particular, Step \(s^* + 1\) itself is a Coin-Fixed-To-1 step, but no honest verifier in \(HSV^{r,s^*}\) has propagated a message for 1, and \(|MSV^{r,s^*}| < t_H\). Thus all honest verifiers in \(HSV^{r,s^*+1}\) stop without propagating anything and set \(B_r = B_\ell^r\): as before, they have received \(m_\ell^{r,1}\) before they receive the desired (r, \(s^* - 1\))-messages.20 The same can be said for all honest verifiers in future steps and all honest users in general. In particular, they all know \(B_r = B_\ell^r\) within the time interval \(I_{r+1}\) and \(T^{r+1} \leq \alpha_{i'}^{r,s^*} + t_{s^*} \leq T^r + \lambda + t_{s^*}\). Case 2.1.b. Event E.b happens and there exists an honest verifier \(i' \in HSV^{r,s^*}\) who should also stop without propagating anything. In this case we have \(s^* - 2 \equiv 1 \mod 3\) and Step \(s^*\) is a Coin-Fixed-To-1 step. The analysis is similar to Case 2.1.a and many details have been omitted. 20If \(\ell\) is malicious, he might send out \(m_\ell^{r,1}\) late, hoping that some honest users/verifiers have not received \(m_\ell^{r,1}\) yet when they receive the desired certificate for it. However, since verifier \(\hat{i} \in HSV^{r,4}\) has set \(b_{\hat{i}} = 0\) and \(v_{\hat{i}} = H(B_\ell^r)\), as before we have that more than half of honest verifiers \(i \in HSV^{r,3}\) have set \(v_i = H(B_\ell^r)\). This further implies more than half of honest verifiers \(i \in HSV^{r,2}\) have set \(v_i = H(B_\ell^r)\), and those (r, 2)-verifiers have all received \(m_\ell^{r,1}\). As the Adversary cannot distinguish a verifier from a non-verifier, he cannot target the propagation of \(m_\ell^{r,1}\) to (r, 2)-verifiers without having the non-verifiers seeing it. In fact, with high probability, more than half (or a good constant fraction) of all honest users have seen \(m_\ell^{r,1}\) after waiting for \(t_2\) from the beginning of their own round r. From here on, the time \(\lambda'\) needed for \(m_\ell^{r,1}\) to reach the remaining honest users is much smaller than \(\Lambda\), and for simplicity we do not write it out in the analysis. If \(4\lambda \geq \lambda'\) then the analysis goes through without any change: by the end of Step 4, all honest users would have received \(m_\ell^{r,1}\). If the size of the block becomes enormous and \(4\lambda < \lambda'\), then in Steps 3 and 4, the protocol could ask each verifier to wait for \(\lambda'/2\) rather than \(2\lambda\), and the analysis continues to hold.
As before, player \(i'\) must have received at least \(t_H\) valid (r, \(s^* - 1\))-messages of the form \((\text{ESIG}_j(1), \text{ESIG}_j(v_j), \sigma_j^{r,s^*-1})\). Again by the definition of \(s^*\), there does not exist a step \(5 \leq s' < s^*\) with \(s' - 2 \equiv 0 \mod 3\), where at least \(t_H\) \((r, s' - 1)\)-verifiers have signed 0 and the same v. Thus player \(i'\) stops without propagating anything; sets \(B_r = B_\epsilon^r\); and sets his own \(\text{CERT}^r\) to be the set of valid (r, \(s^* - 1\))-messages for bit 1 that he has received. Moreover, any other verifier \(i \in HSV^{r,s^*}\) has either stopped with \(B_r = B_\epsilon^r\) , or has set \(b_i = 1\) and propagated \((\text{ESIG}_i(1), \text{ESIG}_i(v_i), \sigma_i^{r,s^*})\). Since player \(i'\) has helped propagating the (r, \(s^* - 1\))-messages in his \(\text{CERT}^r\) by time \(\alpha_{i'}^{r,s^*} + t_{s^*}\), again all honest verifiers in \(HSV^{r,s^*+1}\) stop without propagating anything and set \(B_r = B_\epsilon^r\) . Similarly, all honest users know \(B_r = B_\epsilon^r\) within the time interval \(I_{r+1}\) and \(T^{r+1} \leq \alpha_{i'}^{r,s^*} + t_{s^*} \leq T^r + \lambda + t_{s^*}\). Case 2.2.a. Event E.a happens and there does not exist an honest verifier \(i' \in HSV^{r,s^*}\) who should also stop without propagating anything. In this case, note that player \(i^*\) could have a valid \(\text{CERT}_{i^*}^r\) consisting of the \(t_H\) desired (r, \(s^* - 1\))-messages the Adversary is able to collect or generate. However, the malicious verifiers may not help propagating those messages, so we cannot conclude that the honest users will receive them in time \(\lambda\). In fact, \(|MSV^{r,s^*-1}|\) of those messages may be from malicious (r, \(s^* - 1\))-verifiers, who did not propagate their messages at all and only send them to the malicious verifiers in step \(s^*\). Similar to Case 2.1.a, here we have \(s^* - 2 \equiv 0 \mod 3\), Step \(s^*\) is a Coin-Fixed-To-0 step, and the (r, \(s^* - 1\))-messages in \(\text{CERT}_{i^*}^r\) are for bit 0 and v = \(H(B_\ell^r)\). Indeed, all honest (r, \(s^* - 1\))-verifiers sign v, thus the Adversary cannot generate \(t_H\) valid (r, \(s^* - 1\))-messages for a different \(v'\). Moreover, all honest (r, \(s^*\))-verifiers have waited time \(t_{s^*}\) and do not see > 2/3 majority for bit 1, again because \(|HSV^{r,s^*-1}| + 4|MSV^{r,s^*-1}| < 2n\). Thus every honest verifier \(i \in HSV^{r,s^*}\) sets \(b_i = 0\), \(v_i = H(B_\ell^r)\) by the majority vote, and propagates \(m_i^{r,s^*} =\) \((\text{ESIG}_i(0), \text{ESIG}_i(H(B_\ell^r)), \sigma_i^{r,s^*})\) at time \(\alpha_i^{r,s^*} + t_{s^*}\). Now consider the honest verifiers in Step \(s^* + 1\) (which is a Coin-Fixed-To-1 step). If the Adversary actually sends the messages in \(\text{CERT}_{i^*}^r\) to some of them and causes them to stop, then similar to Case 2.1.a, all honest users know \(B_r = B_\ell^r\) within the time interval \(I_{r+1}\) and \(T^{r+1} \leq T^r + \lambda + t_{s^*+1}\). Otherwise, all honest verifiers in Step \(s^* + 1\) have received all the (r, \(s^*\))-messages for 0 and \(H(B_\ell^r)\) from \(HSV^{r,s^*}\) after waiting time \(t_{s^*+1}\), which leads to > 2/3 majority, because \(|HSV^{r,s^*}| > 2|MSV^{r,s^*}|\). Thus all the verifiers in \(HSV^{r,s^*+1}\) propagate their messages for 0 and \(H(B_\ell^r)\) accordingly. Note that the verifiers in \(HSV^{r,s^*+1}\) do not stop with \(B_r = B_\ell^r\), because Step \(s^* + 1\) is not a Coin-Fixed-To-0 step. Now consider the honest verifiers in Step \(s^* + 2\) (which is a Coin-Genuinely-Flipped step). If the Adversary sends the messages in \(\text{CERT}_{i^*}^r\) to some of them and causes them to stop, then again all honest users know \(B_r = B_\ell^r\) within the time interval \(I_{r+1}\) and \(T^{r+1} \leq T^r + \lambda + t_{s^*+2}\).
Otherwise, all honest verifiers in Step \(s^* + 2\) have received all the (r, \(s^* + 1\))-messages for 0 and \(H(B_\ell^r)\) from \(HSV^{r,s^*+1}\) after waiting time \(t_{s^*+2}\), which leads to > 2/3 majority. Thus all of them propagate their messages for 0 and \(H(B_\ell^r)\) accordingly: that is they do not “flip a coin” in this case. Again, note that they do not stop without propagating, because Step \(s^* + 2\) is not a Coin-Fixed-To-0 step. Finally, for the honest verifiers in Step \(s^* + 3\) (which is another Coin-Fixed-To-0 step), all of them would have received at least \(t_H\) valid messages for 0 and \(H(B_\ell^r)\) from \(HSV^{s^*+2}\), if they really wait time \(t_{s^*+3}\). Thus, whether or not the Adversary sends the messages in \(\text{CERT}_{i^*}^r\) to any of them, all verifiers in \(HSV^{r,s^*+3}\) stop with \(B_r = B_\ell^r\), without propagating anything. Depending on how the Adversary acts, some of them may have their own \(\text{CERT}^r\) consisting of those \((r, s^*-1)\)-messages in \(\text{CERT}_{i^*}^r\), and the others have their own \(\text{CERT}^r\) consisting of those (r, \(s^* + 2\))-messages. In any case, all honest users know \(B_r = B_\ell^r\) within the time interval \(I_{r+1}\) and \(T^{r+1} \leq T^r + \lambda + t_{s^*+3}\). Case 2.2.b. Event E.b happens and there does not exist an honest verifier \(i' \in HSV^{r,s^*}\) who should also stop without propagating anything. The analysis in this case is similar to those in Case 2.1.b and Case 2.2.a, thus many details have been omitted. In particular, \(\text{CERT}_{i^*}^r\) consists of the \(t_H\) desired \((r, s^*-1)\)-messages for bit 1 that the Adversary is able to collect or generate, \(s^* - 2 \equiv 1 \mod 3\), Step \(s^*\) is a Coin-Fixed-To-1 step, and no honest \((r, s^*)\)-verifier could have seen > 2/3 majority for 0. Thus, every verifier \(i \in HSV^{r,s^*}\) sets \(b_i = 1\) and propagates \(m_i^{r,s^*} = (\text{ESIG}_i(1), \text{ESIG}_i(v_i), \sigma_i^{r,s^*})\) at time \(\alpha_i^{r,s^*} + t_{s^*}\). Similar to Case 2.2.a, in at most 3 more steps (i.e., the protocol reaches Step \(s^* + 3\), which is another Coin-Fixed-To-1 step), all honest users know \(B_r = B_\epsilon^r\) within the time interval \(I_{r+1}\). Moreover, \(T^{r+1}\) may be \(\leq T^r + \lambda + t_{s^*+1}\), or \(\leq T^r + \lambda + t_{s^*+2}\), or \(\leq T^r + \lambda + t_{s^*+3}\), depending on when is the first time an honest verifier is able to stop without propagating. Combining the four sub-cases, we have that all honest users know \(B_r\) within the time interval \(I_{r+1}\), with \(T^{r+1} \leq T^r + \lambda + t_{s^*}\) in Cases 2.1.a and 2.1.b, and \(T^{r+1} \leq T^r + \lambda + t_{s^*+3}\) in Cases 2.2.a and 2.2.b. It remains to upper-bound \(s^*\) and thus \(T^{r+1}\) for Case 2, and we do so by considering how many times the Coin-Genuinely-Flipped steps are actually executed in the protocol: that is, some honest verifiers actually have flipped a coin. In particular, arbitrarily fix a Coin-Genuinely-Flipped step \(s'\) (i.e., \(7 \leq s' \leq m + 2\) and \(s' - 2 \equiv 2 \mod 3\)), and let \(\ell' \triangleq \arg \min_{j \in SV^{r,s'-1}} H(\sigma_j^{r,s'-1})\). For now let us assume \(s' < s^*\), because otherwise no honest verifier actually flips a coin in Step \(s'\), according to previous discussions. By the definition of \(SV^{r,s'-1}\), the hash value of the credential of \(\ell'\) is also the smallest among all users in \(PK^{r-k}\). Since the hash function is a random oracle, ideally player \(\ell'\) is honest with probability at least h. As we will show later, even if the Adversary tries his best to predict the output of the random oracle and tilt the probability, player \(\ell'\) is still honest with probability
at least \(p_h = h^2(1 + h - h^2)\). Below we consider the case when that indeed happens: that is, \(\ell' \in HSV^{r,s'-1}\). Note that every honest verifier \(i \in HSV^{r,s'}\) has received all messages from \(HSV^{r,s'-1}\) by time \(\alpha_i^{r,s'} + t_{s'}\). If player i needs to flip a coin (i.e., he has not seen > 2/3 majority for the same bit \(b \in \{0, 1\}\)), then he sets \(b_i = \text{lsb}(H(\sigma_{\ell'}^{r,s'-1}))\). If there exists another honest verifier \(i' \in HSV^{r,s'}\) who has seen > 2/3 majority for a bit \(b \in \{0, 1\}\), then by Property (d) of Lemma 5.5, no honest verifier in \(HSV^{r,s'}\) would have seen > 2/3 majority for a bit \(b' \neq b\). Since \(\text{lsb}(H(\sigma_{\ell'}^{r,s'-1})) = b\) with probability \(1/2\), all honest verifiers in \(HSV^{r,s'}\) reach an agreement on b with probability \(1/2\). Of course, if such a verifier \(i'\) does not exist, then all honest verifiers in \(HSV^{r,s'}\) agree on the bit \(\text{lsb}(H(\sigma_{\ell'}^{r,s'-1}))\) with probability \(1\). Combining the probability for \(\ell' \in HSV^{r,s'-1}\), we have that the honest verifiers in \(HSV^{r,s'}\) reach an agreement on a bit \(b \in \{0, 1\}\) with probability at least \(\frac{p_h}{2} = \frac{h^2(1+h-h^2)}{2}\). Moreover, by induction on the majority vote as before, all honest verifiers in \(HSV^{r,s'}\) have their \(v_i\)'s set to be \(H(B_\ell^r)\). Thus, once an agreement on b is reached in Step \(s'\), \(T^{r+1}\) is either \(\leq T^r + \lambda + t_{s'+1}\) or \(\leq T^r + \lambda + t_{s'+2}\), depending on whether \(b = 0\) or \(b = 1\), following the analysis of Cases 2.1.a and 2.1.b. In particular, no further Coin-Genuinely-Flipped step will be executed: that is, the verifiers in such steps still check that they are the verifiers and thus wait, but they will all stop without propagating anything. Accordingly, before Step \(s^*\), the number of times the Coin-GenuinelyFlipped steps are executed is distributed according to the random variable \(L_r\). Letting Step \(s'\) be the last Coin-Genuinely-Flipped step according to \(L_r\), by the construction of the protocol we have \(s' = 4 + 3L_r\). When should the Adversary make Step \(s^*\) happen if he wants to delay \(T^{r+1}\) as much as possible? We can even assume that the Adversary knows the realization of \(L_r\) in advance. If \(s^*\) > \(s'\) then it is useless, because the honest verifiers have already reached an agreement in Step \(s'\). To be sure, in this case \(s^*\) would be \(s' + 1\) or \(s' + 2\), again depending on whether \(b = 0\) or \(b = 1\). However, this is actually Cases 2.1.a and 2.1.b, and the resulting \(T^{r+1}\) is exactly the same as in that case. More precisely, \(T^{r+1} \leq T^r + \lambda + t_{s^*} \leq T^r + \lambda + t_{s'+2}\). If \(s^*\) < \(s' - 3\) —that is, \(s^*\) is before the second-last Coin-Genuinely-Flipped step— then by the analysis of Cases 2.2.a and 2.2.b, \(T^{r+1} \leq T^r + \lambda + t_{s^*+3} < T^r + \lambda + t_{s'}\). That is, the Adversary is actually making the agreement on \(B_r\) happen faster. If \(s^* = s' - 2\) or \(s' - 1\) —that is, the Coin-Fixed-To-0 step or the Coin-Fixed-To-1 step immediately before Step \(s'\)— then by the analysis of the four sub-cases, the honest verifiers in Step \(s'\) do not get to flip coins anymore, because they have either stopped without propagating, or have seen > 2/3 majority for the same bit \(b\). Therefore we have \(T^{r+1} \leq T^r + \lambda + t_{s^*+3} \leq T^r + \lambda + t_{s'+2}\).
In sum, no matter what \(s^*\) is, we have \(T^{r+1} \leq T^r + \lambda + t_{s'+2} = T^r + \lambda + t_{3L_r+6}\) \(= T^r + \lambda + (2(3L_r + 6) - 3)\lambda + \Lambda\) \(= T^r + (6L_r + 10)\lambda + \Lambda\), as we wanted to show. The worst case is when \(s^* = s' - 1\) and Case 2.2.b happens. Combining Cases 1 and 2 of the binary BA protocol, Lemma 5.3 holds. ■ 5.9 Security of the Seed \(Q_r\) and Probability of An Honest Leader It remains to prove Lemma 5.4. Recall that the verifiers in round \(r\) are taken from \(PK^{r-k}\) and are chosen according to the quantity \(Q_{r-1}\). The reason for introducing the look-back parameter \(k\) is to make sure that, back at round \(r - k\), when the Adversary is able to add new malicious users to \(PK^{r-k}\), he cannot predict the quantity \(Q_{r-1}\) except with negligible probability. Note that the hash function is a random oracle and \(Q_{r-1}\) is one of its inputs when selecting verifiers for round \(r\). Thus, no matter how malicious users are added to \(PK^{r-k}\), from the Adversary's point of view each one of them is still selected to be a verifier in a step of round \(r\) with the required probability \(p\) (or \(p_1\) for Step 1). More precisely, we have the following lemma. Lemma 5.6. With \(k = O(\log_{1/2} F)\), for each round \(r\), with overwhelming probability the Adversary did not query \(Q_{r-1}\) to the random oracle back at round \(r - k\). Proof. We proceed by induction. Assume that for each round \(\gamma < r\), the Adversary did not query \(Q_{\gamma-1}\) to the random oracle back at round \(\gamma - k\).21 Consider the following mental game played by the Adversary at round \(r - k\), trying to predict \(Q_{r-1}\). In Step 1 of each round \(\gamma = r - k, \ldots, r - 1\), given a specific \(Q_{\gamma-1}\) not queried to the random oracle, by ordering the players \(i \in PK^{\gamma-k}\) according to the hash values \(H(\text{SIG}_i(\gamma, 1, Q_{\gamma-1}))\) increasingly, we obtain a random permutation over \(PK^{\gamma-k}\). By definition, the leader \(\ell_\gamma\) is the first user in the permutation and is honest with probability \(h\). Moreover, when \(PK^{\gamma-k}\) is large enough, for any integer \(x \geq 1\), the probability that the first \(x\) users in the permutation are all malicious but the \((x + 1)\)st is honest is \((1 - h)^x h\). If \(\ell_\gamma\) is honest, then \(Q_\gamma = H(\text{SIG}_{\ell_\gamma}(Q_{\gamma-1}), \gamma)\). As the Adversary cannot forge the signature of \(\ell_\gamma\), \(Q_\gamma\) is distributed uniformly at random from the Adversary's point of view and, except with exponentially small probability,22 was not queried to \(H\) at round \(r - k\). Since each \(Q_{\gamma+1}, Q_{\gamma+2}, \ldots, Q_{r-1}\) respectively is the output of \(H\) with \(Q_\gamma, Q_{\gamma+1}, \ldots, Q_{r-2}\) as one of the inputs, they all look random to the Adversary and the Adversary could not have queried \(Q_{r-1}\) to \(H\) at round \(r - k\). Accordingly, the only case where the Adversary can predict \(Q_{r-1}\) with good probability at round \(r - k\) is when all the leaders \(\ell_{r-k}, \ldots, \ell_{r-1}\) are malicious. Again consider a round \(\gamma \in \{r - k \ldots, r - 1\}\) and the random permutation over \(PK^{\gamma-k}\) induced by the corresponding hash values. If for some \(x \geq 2\), the first \(x - 1\) users in the permutation are all malicious and the \(x\)-th is honest, then the Adversary has \(x\) possible choices for \(Q_\gamma\): either of the form \(H(\text{SIG}_i(Q_{\gamma-1}, \gamma))\), where \(i\) is one of 21As \(k\) is a small integer, without loss of generality one can assume that the first \(k\) rounds of the protocol are run under a safe environment and the inductive hypothesis holds for those rounds. 22That is, exponential in the length of the output of \(H\). Note that this probability is way smaller than \(F\).
the first \(x - 1\) malicious users, by making player \(i\) the actually leader of round \(\gamma\); or \(H(Q_{\gamma-1}, \gamma)\), by forcing \(B_\gamma = B_\gamma^\epsilon\). Otherwise, the leader of round \(\gamma\) will be the first honest user in the permutation and \(Q_{r-1}\) becomes unpredictable to the Adversary. Which of the above \(x\) options of \(Q_\gamma\) should the Adversary pursue? To help the Adversary answer this question, in the mental game we actually make him more powerful than he actually is, as follows. First of all, in reality, the Adversary cannot compute the hash of a honest user's signature, thus cannot decide, for each \(Q_\gamma\), the number \(x(Q_\gamma)\) of malicious users at the beginning of the random permutation in round \(\gamma + 1\) induced by \(Q_\gamma\). In the mental game, we give him the numbers \(x(Q_\gamma)\) for free. Second of all, in reality, having the first \(x\) users in the permutation all being malicious does not necessarily mean they can all be made into the leader, because the hash values of their signatures must also be less than \(p_1\). We have ignored this constraint in the mental game, giving the Adversary even more advantages. It is easy to see that in the mental game, the optimal option for the Adversary, denoted by \(\hat{Q}_\gamma\), is the one that produces the longest sequence of malicious users at the beginning of the random permutation in round \(\gamma + 1\). Indeed, given a specific \(Q_\gamma\), the protocol does not depend on \(Q_{\gamma-1}\) anymore and the Adversary can solely focus on the new permutation in round \(\gamma + 1\), which has the same distribution for the number of malicious users at the beginning. Accordingly, in each round \(\gamma\), the above mentioned \(\hat{Q}_\gamma\) gives him the largest number of options for \(Q_{\gamma+1}\) and thus maximizes the probability that the consecutive leaders are all malicious. Therefore, in the mental game the Adversary is following a Markov Chain from round \(r - k\) to round \(r - 1\), with the state space being \(\{0\} \cup \{x : x \geq 2\}\). State 0 represents the fact that the first user in the random permutation in the current round \(\gamma\) is honest, thus the Adversary fails the game for predicting \(Q_{r-1}\); and each state \(x \geq 2\) represents the fact that the first \(x - 1\) users in the permutation are malicious and the \(x\)-th is honest, thus the Adversary has \(x\) options for \(Q_\gamma\). The transition probabilities \(P(x, y)\) are as follows. • \(P(0, 0) = 1\) and \(P(0, y) = 0\) for any \(y \geq 2\). That is, the Adversary fails the game once the first user in the permutation becomes honest. • \(P(x, 0) = h^x\) for any \(x \geq 2\). That is, with probability \(h^x\), all the \(x\) random permutations have their first users being honest, thus the Adversary fails the game in the next round. • For any \(x \geq 2\) and \(y \geq 2\), \(P(x, y)\) is the probability that, among the \(x\) random permutations induced by the \(x\) options of \(Q_\gamma\), the longest sequence of malicious users at the beginning of some of them is \(y - 1\), thus the Adversary has \(y\) options for \(Q_{\gamma+1}\) in the next round. That is, \(P(x, y) = \left(\sum_{i=0}^{y-1} (1 - h)^i h\right)^x - \left(\sum_{i=0}^{y-2} (1 - h)^i h\right)^x = (1 - (1 - h)^y)^x - (1 - (1 - h)^{y-1})^x\). Note that state 0 is the unique absorbing state in the transition matrix \(P\), and every other state \(x\) has a positive probability of going to 0. We are interested in upper-bounding the number \(k\) of rounds needed for the Markov Chain to converge to 0 with overwhelming probability: that is, no matter which state the chain starts at, with overwhelming probability the Adversary loses the game and fails to predict \(Q_{r-1}\) at round \(r - k\). Consider the transition matrix \(P^{(2)} \triangleq P \cdot P\) after two rounds. It is easy to see that \(P^{(2)}(0, 0) = 1\) and \(P^{(2)}(0, x) = 0\) for any \(x \geq 2\). For any \(x \geq 2\) and \(y \geq 2\), as \(P(0, y) = 0\), we have \(P^{(2)}(x, y) = P(x, 0)P(0, y) + \sum_{z \geq 2} P(x, z)P(z, y) = \sum_{z \geq 2} P(x, z)P(z, y)\).
Letting \(\bar{h} \triangleq 1 - h\), we have \(P(x, y) = (1 - \bar{h}^y)^x - (1 - \bar{h}^{y-1})^x\) and \(P^{(2)}(x, y) = \sum_{z \geq 2} [(1 - \bar{h}^z)^x - (1 - \bar{h}^{z-1})^x][(1 - \bar{h}^y)^z - (1 - \bar{h}^{y-1})^z]\). Below we compute the limit of \(\frac{P^{(2)}(x,y)}{P(x,y)}\) as \(h\) goes to 1 —that is, \(\bar{h}\) goes to 0. Note that the highest order of \(\bar{h}\) in \(P(x, y)\) is \(\bar{h}^{y-1}\), with coefficient \(x\). Accordingly, \(\lim_{h \to 1} \frac{P^{(2)}(x, y)}{P(x, y)} = \lim_{\bar{h} \to 0} \frac{P^{(2)}(x, y)}{P(x, y)} = \lim_{\bar{h} \to 0} \frac{P^{(2)}(x, y)}{x\bar{h}^{y-1} + O(\bar{h}^y)}\) \(= \lim_{\bar{h} \to 0} \frac{\sum_{z \geq 2} [x\bar{h}^{z-1} + O(\bar{h}^z)][z\bar{h}^{y-1} + O(\bar{h}^y)]}{x\bar{h}^{y-1} + O(\bar{h}^y)} = \lim_{\bar{h} \to 0} \frac{2x\bar{h}^y + O(\bar{h}^{y+1})}{x\bar{h}^{y-1} + O(\bar{h}^y)}\) \(= \lim_{\bar{h} \to 0} \frac{2x\bar{h}^y}{x\bar{h}^{y-1}} = \lim_{\bar{h} \to 0} 2\bar{h} = 0\). When \(h\) is sufficiently close to 1,23 we have \(\frac{P^{(2)}(x, y)}{P(x, y)} \leq \frac{1}{2}\) for any \(x \geq 2\) and \(y \geq 2\). By induction, for any \(k > 2\), \(P^{(k)} \triangleq P^k\) is such that • \(P^{(k)}(0, 0) = 1\), \(P^{(k)}(0, x) = 0\) for any \(x \geq 2\), and • for any \(x \geq 2\) and \(y \geq 2\), \(P^{(k)}(x, y) = P^{(k-1)}(x, 0)P(0, y) + \sum_{z \geq 2} P^{(k-1)}(x, z)P(z, y) = \sum_{z \geq 2} P^{(k-1)}(x, z)P(z, y)\) \(\leq \sum_{z \geq 2} \frac{P(x, z)}{2^{k-2}} \cdot P(z, y) = \frac{P^{(2)}(x, y)}{2^{k-2}} \leq \frac{P(x, y)}{2^{k-1}}\). As \(P(x, y) \leq 1\), after \(1 - \log_2 F\) rounds, the transition probability into any state \(y \geq 2\) is negligible, starting with any state \(x \geq 2\). Although there are many such states \(y\), it is easy to see that \(\lim_{y \to +\infty} \frac{P(x, y)}{P(x, y + 1)} = \lim_{y \to +\infty} \frac{(1 - \bar{h}^y)^x - (1 - \bar{h}^{y-1})^x}{(1 - \bar{h}^{y+1})^x - (1 - \bar{h}^y)^x} = \lim_{y \to +\infty} \frac{\bar{h}^{y-1} - \bar{h}^y}{\bar{h}^y - \bar{h}^{y+1}} = \frac{1}{\bar{h}} = \frac{1}{1 - h}\). Therefore each row \(x\) of the transition matrix \(P\) decreases as a geometric sequence with rate \(\frac{1}{1-h} > 2\) when \(y\) is large enough, and the same holds for \(P^{(k)}\). Accordingly, when \(k\) is large enough but still on the order of \(\log_{1/2} F\), \(\sum_{y \geq 2} P^{(k)}(x, y) < F\) for any \(x \geq 2\). That is, with overwhelming probability the Adversary loses the game and fails to predict \(Q_{r-1}\) at round \(r - k\). For \(h \in (2/3, 1]\), a more complex analysis shows that there exists a constant \(C\) slightly larger than 1/2, such that it suffices to take \(k = O(\log_C F)\). Thus Lemma 5.6 holds. ■ Lemma 5.4. (restated) Given Properties 1–3 for each round before \(r\), \(p_h = h^2(1 + h - h^2)\) for \(L_r\), and the leader \(\ell_r\) is honest with probability at least \(p_h\). 23For example, \(h = 80\%\) as suggested by the specific choices of parameters.
Proof. Following Lemma 5.6, the Adversary cannot predict \(Q_{r-1}\) back at round \(r - k\) except with negligible probability. Note that this does not mean the probability of an honest leader is \(h\) for each round. Indeed, given \(Q_{r-1}\), depending on how many malicious users are at the beginning of the random permutation of \(PK^{r-k}\), the Adversary may have more than one options for \(Q_r\) and thus can increase the probability of a malicious leader in round \(r + 1\) —again we are giving him some unrealistic advantages as in Lemma 5.6, so as to simplify the analysis. However, for each \(Q_{r-1}\) that was not queried to \(H\) by the Adversary back at round \(r - k\), for any \(x \geq 1\), with probability \((1 - h)^{x-1} h\) the first honest user occurs at position \(x\) in the resulting random permutation of \(PK^{r-k}\). When \(x = 1\), the probability of an honest leader in round \(r + 1\) is indeed \(h\); while when \(x = 2\), the Adversary has two options for \(Q_r\) and the resulting probability is \(h^2\). Only by considering these two cases, we have that the probability of an honest leader in round \(r + 1\) is at least \(h \cdot h + (1 - h)h \cdot h^2 = h^2(1 + h - h^2)\) as desired. Note that the above probability only considers the randomness in the protocol from round \(r - k\) to round \(r\). When all the randomness from round 0 to round \(r\) is taken into consideration, \(Q_{r-1}\) is even less predictable to the Adversary and the probability of an honest leader in round \(r + 1\) is at least \(h^2(1 + h - h^2)\). Replacing \(r + 1\) with \(r\) and shifts everything back by one round, the leader \(\ell_r\) is honest with probability at least \(h^2(1 + h - h^2)\), as desired. Similarly, in each Coin-Genuinely-Flipped step \(s\), the "leader" of that step —that is the verifier in \(SV^{r,s}\) whose credential has the smallest hash value, is honest with probability at least $h^2(1 + h - h^2)\(. Thus \)p_h = h^2(1 + h - h^2)\( for \)L_r$ and Lemma 5.4 holds. ■
Algorand ′
1 在本节中,我们构建了在以下假设下工作的 Algorand ' 版本。 诚实的大多数用户假设:每个 PKr 中超过 2/3 的用户是诚实的。 在第 8 节中,我们展示了如何用所需的诚实多数来替换上述假设 金钱假设。 5.1 附加符号和参数 符号 • m \(\in\)Z+:二进制BA协议中的最大步数,3的倍数。 • Lr \(\leq\)m/3:随机变量,代表看到 1 所需的伯努利试验次数, 当每次试验为 1 时,概率为 ph 2 并且最多有 m/3 次试验。如果所有试验都失败了 Lr \(\triangleq\)m/3。 Lr 将用于确定生成区块 Br 所需时间的上限。 • tH = 2n 3 + 1:协议结束条件所需的签名数量。 • CERT r:Br 的证书。它是来自适当验证者的 H(Br) 的一组 tH 签名 朗德河 参数 • 各种参数之间的关系。 — 对于第 r 轮的每一步 s > 1,选择 n 使得以压倒性的概率, |HSV r,s| > 2|MSV r,s| 和 |HSV r,s| + 4|MSV r,s| < 2n。 h的值越接近1,n需要越小。特别是,我们使用(变体 of) Chernoffbounds 以确保所需条件以压倒性概率成立。 — m 的选择使得 Lr < m/3 以压倒性的概率出现。 • 重要参数的选择示例。 — F = 10−12。 — n \(\approx\)1500,k = 40,m = 180。5.2 在 Algorand ' 中实现临时密钥 1 正如已经提到的,我们希望验证者 i \(\in\)SV r,s 对他的消息 mr,s 进行数字签名 我 步骤的 r 轮中的 s,相对于临时公钥 pkr,s i ,使用临时秘密密钥 skr,s 我 那个 他在使用后立即销毁。因此,我们需要一种有效的方法来确保每个用户都可以 验证 pkr,s 我 确实是用来验证我的 Mr,s 签名的密钥 我。我们这样做是通过(尽最大努力 据我们所知)基于身份的签名方案的新用途。 在较高层面上,在这样的方案中,中央机构 A 生成一个公共主密钥 PMK, 以及相应的秘密主密钥 SMK。给定玩家 U 的身份 U,A 计算, 通过SMK,得到一个相对于公钥U的秘密签名密钥skU,并私下将skU给 U.(事实上,在基于身份的数字签名方案中,用户U的公钥就是U本身!) 这样,如果 A 在计算出他想要启用的用户的密钥后销毁 SMK 产生数字签名,并且不保留任何计算出的密钥,那么 U 是唯一一个 可以对与公钥 U 相关的消息进行数字签名。因此,任何知道“U 的名字”的人, 自动知道 U 的公钥,因此可以验证 U 的签名(也可能使用 公共主密钥 PMK)。 在我们的应用中,权限 A 是用户 i,所有可能用户 U 的集合与 比如说 S = {i}\(\times\){r′, 中的圆步对 (r, s)。 。 。 , r′ +106}\(\times\){1, . 。 。 , m+3},其中 r′ 是给定的 一轮,m + 3 是一轮内可能发生的步数的上限。这个 方式,pkr,s 我 \(\triangleq\)(i, r, s),这样每个人都看到i的签名SIGr,s PKR,S 我(先生,s 我)可以,以压倒性的 概率,立即在 r' 之后的前一百万轮 r 中验证它。 换句话说,i首先生成PMK和SMK。然后,他公开PMK是i的主人 任意一轮 r \(\in\)[r′, r′ + 106] 的公钥,并使用 SMK 私下生成和存储秘密 关键 skr,s 我 对于每个三元组 (i, r, s) \(\in\)S。完成后,他摧毁了 SMK。如果他确定自己不是 SV r,s 的一部分,那么我可能会离开 skr,s 我 单独(因为协议不要求他验证 r) 轮步骤 s 中的任何消息。否则,我首先使用 skr,s 我 对他的消息进行数字签名 Mr,s 我 , 和 然后摧毁skr,s 我。 请注意,当他第一次进入系统时,我可以公开他的第一个公共主密钥。也就是说, 将 i 带入系统的相同支付 \(\wp\)(在 r′ 轮或接近 r′ 轮),也可能 根据 i 的要求,指定 i 的任意轮 r \(\in\)[r′, r′ + 106] 的公共主密钥是 PMK — 例如,通过 包括一对 (PMK, [r', r' + 106]) 形式。 另请注意,由于 m + 3 是一轮中的最大步数,假设一轮 只需一分钟,如此生成的临时密钥的存储将持续近两年。同时 时间,这些短暂的密钥不会花太长时间来生成。使用基于椭圆曲线 在具有 32B 密钥的系统中,每个秘密密钥的计算时间为几微秒。因此,如果 m + 3 = 180, 那么所有 180M 密钥可以在不到一小时的时间内计算出来。 当当前回合接近 r′ + 106 时,为了处理接下来的一百万回合,i 生成一个新的 (PMK′, SMK′) 对,并通过以下方式告知他的下一个临时密钥存储是什么 - 例如 - 让 SIGi(PMK', [r' + 106 + 1, r' + 2 \(\cdot\) 106 + 1]) 输入一个新块,或者作为 单独的“交易”或作为付款一部分的一些附加信息。通过这样做, 我通知每个人,他/她应该在接下来的时间里使用 PMK′ 来验证我的临时签名 万发。等等。 (请注意,遵循此基本方法,无需其他方法即可实现临时密钥 使用基于身份的签名当然是可能的。例如,通过 Merkle trees.16) 16在这个方法中,我生成一个公私密钥对(pkr,s 我,skr,s 我 ) 对于 —say— 中的每个回合步对 (r, s)当然也可以采用其他方式实现临时密钥,例如通过 Merkle trees。 5.3 匹配 Algorand ′ 的步骤 1 与BA⋆的那些 正如我们所说,一轮在 Algorand ' 1 最多有 m + 3 步。 步骤 1. 在这一步中,每个潜在领导者 i 计算并传播他的候选区块 Br 我, 连同他自己的凭证,\(\sigma\)r,1 我。 回想一下,这个凭证明确地标识了 i。之所以如此,是因为 \(\sigma\)r,1 我 \(\triangleq\)SIGi(r, 1, Qr−1)。 潜在验证者 i 还传播其正确的数字签名 H(Br 我)。 不涉及付款或凭证,i 的此签名与他的短暂公共相关 密钥 pkr,1 i :也就是说,他传播 sigpkr,1 我 (H(Br 我))。 鉴于我们的惯例,而不是传播 Br 我 和 sigpkr,1 我 (H(Br 我)),他本可以 传播的 SIGpkr,1 我 (H(Br 我))。 然而,在我们的分析中,我们需要显式访问 sigpkr,1 我 (H(Br 我))。 步骤 2. 在这一步中,每个验证者 i 设置 \(\ell\)r 我将成为具有 hashed 证书的潜在领导者 是最小的,并且 Br i 是 \(\ell\)r 提出的区块 我。因为,为了效率,我们 希望就 H(Br) 达成一致,而不是直接就 Br 达成一致,我传播他想要的信息 在 BA⋆ 的第一步中以初始值 v′ 传播 我 = H(Br 我)。也就是说,他传播 v′ 我, 当然,是在短暂签署之后。 (即,在相对于正确的临时签名后 公钥,在本例中为 pkr,2 i .) 当然,我也传输了他自己的凭证。 由于 BA⋆ 的第一步包含了分级共识协议 GC 的第一步, Algorand '的2对应于GC的第一步。 步骤3. 在这一步中,每个验证者i \(\in\)SV r,2 执行BA⋆的第二步。也就是说,他发送 他会在 GC 第二步中发送相同的消息。再说一次,我的信息是短暂的 签名并附有我的证书。 (从现在开始,我们将省略验证者 短暂地签署他的消息并传播他的凭证。) 步骤 4. 在这一步中,每个验证器 i \(\in\)SV r,4 计算 GC 的输出 (vi, gi),并且短暂地 签署并发送与他在 BA⋆第三步中发送的相同的消息,即在 BBA⋆的第一步,如果gi = 2则初始位为0,否则为1。 步骤 s = 5,. 。 。 , m + 2。这样的步骤,如果达到的话,对应于 BA⋆ 的步骤 s -1,因此 BBA⋆的步骤s -3。 由于我们的传播模型足够异步,因此我们必须考虑以下可能性 在这样的步骤 s 的中间,通过证明他的信息到达验证者 i \(\in\)SV r,s 该块 Br 已被选择。在这种情况下,i 停止自己执行第 r 轮 Algorand ′,并开始执行他的回合(r + 1)指令。 {r′,. 。 。 , r′ + 106} \(\times\) {1, . 。 。 ,m+3}。 然后他以规范的方式对这些公钥进行排序,存储第 j 个公钥 键入 Merkle tree 的第 j 个叶子,并计算他公开的根值 Ri。当他想要签名的时候 与密钥 pkr,s 相关的消息 我 , i 不仅提供了实际的签名,还提供了 pkr,s 的验证路径 我 相对于Ri。请注意,此身份验证路径还证明了 pkr,s 我 存储在第 j 个叶子中。其余的 详细信息可以轻松填写。因此,除了相应的指令之外,验证器 i \(\in\)SV r,s 的指令 BBA⋆的步骤s -3,包括检查BBA⋆的执行是否在先前已停止 步骤s′。由于 BBA⋆ 只能在 Coin-Fixed-0 Step 或 Coin-Fixed-1 Step 中停止, 指令区分是否 A(结束条件 0):s′ -2 ≡0 mod 3,或 B(结束条件1):s′ -2 ≡1 mod 3。 事实上,在情况 A 中,块 Br 是非空的,因此需要额外的指令来 确保我正确重建 Br 及其正确的证书 CERT r。在情况 B 中, 块 Br 为空,因此指示 i 设置 Br = Br \(\varepsilon\) = (r, \(\emptyset\), H(Qr−1, r), H(Br−1)), 并计算 CERT r。 如果在执行步骤 s 的过程中,我没有看到任何证据表明块 Br 已经 生成后,他发送的消息与他在 BBA⋆的步骤 s -3 中发送的消息相同。 步骤 m + 3。如果在步骤 m + 3 期间,i \(\in\)SV r,m+3 看到块 Br 已经在 先前的步骤 s',然后他按照上面所解释的进行。 否则,我不会发送他在 BBA⋆的步骤 m 中发送的相同消息,而是 根据他掌握的信息,指示计算 Br 及其相应的 证书 CERT r。 事实上,回想一下,我们将一轮的总步数设置为 m + 3。 5.4 实际协议 回想一下,在第 r 轮的每个步骤 s 中,验证者 i \(\in\)SV r,s 使用他的长期公钥对 出示他的凭证 \(\sigma\)r,s 我 \(\triangleq\)SIGi(r, s, Qr−1),以及 SIGi Qr−1 如果 s = 1。验证者 i 使用他的临时密钥 skr,s 我 签署他的 (r, s) 消息 mr,s 我。为简单起见,当 r 和 s 为 清楚,我们写 esigi(x) 而不是 sigpkr,s i (x) 表示 i 的值的固有临时签名 x 在第 r 轮的步骤 s 中,并写入 ESIGi(x) 而不是 SIGpkr,s i (x) 表示 (i, x, esigi(x))。 第 1 步:区块提案 对每个用户 i \(\in\)PKr−k 的说明:用户 i 一旦他开始他自己的第 r 轮步骤 1 知道 Br−1。 • 用户 i 根据 Br−1 的第三个分量计算 Qr−1 并检查 i \(\in\)SV r,1 或 不。 • 如果i /\(\varepsilon\)SV r,1,则i 立即停止自己执行步骤1。 • 如果 i \(\in\)SV r,1,即,如果 i 是潜在领导者,那么他将收取具有以下特征的第 r 轮付款: 到目前为止已传播给他并计算最大支付集 PAY r 我来自他们。接下来,他 计算他的“候选块” Br 我 = (r, 支付 r i , SIGi(Qr−1), H(Br−1))。最后,他计算出 消息先生,1 我 = (Br i , esigi(H(Br i )), \(\sigma\)r,1 i ), 销毁他的临时密钥 skr,1 我,然后 传播 mr,1 我。评论。 在实践中,为了缩短步骤 1 的全局执行时间,重要的是 (r, 1)- 消息是有选择地传播的。 也就是说,对于系统中的每个用户 i,对于第一个 (r, 1)- 他收到并成功验证的消息,17 玩家 i 像往常一样传播它。对于所有的 其他 (r, 1) - 玩家 i 收到并成功验证的消息,只有在 hash 时他才会传播它 它包含的凭证的值是所包含凭证的 hash 值中最小的 到目前为止,他已收到并成功验证的所有 (r, 1) 消息中。此外,按照建议 作者:Georgios Vlachos,每个潜在领导者 i 也传播他的凭证 \(\sigma\)r,1 是有用的 我 分别:这些小消息的传播速度比块更快,确保 mr,1 的及时传播 j 的 其中包含的凭据具有较小的 hash 值,而使那些具有较大的 hash 值 很快消失。 第二步:分级共识协议GC的第一步 对每个用户 i \(\in\)PKr−k 的说明:用户 i 一旦他开始他自己的第 r 轮步骤 2 知道 Br−1。 • 用户 i 根据 Br−1 的第三个分量计算 Qr−1 并检查 i 是否 \(\in\)SV r,2 或 不。 • 如果i /\(\varepsilon\)SV r,2 则i 立即停止自己执行步骤2。 • 如果i \(\in\)SV r,2,则在等待一段时间t2 \(\triangleq\) \(\lambda\) + Λ 后,i 的行为如下。 1. 他找到用户\(\ell\)使得H(\(\sigma\)r,1 \(\ell\)) \(\leq\)H(\(\sigma\)r,1 j ) 对于所有凭证 \(\sigma\)r,1 j 是的一部分 到目前为止他收到的已成功验证的 (r, 1) 消息。 2. 如果他收到来自 \(\ell\) 的有效消息 mr,1 \(\ell\) = (Br \(\ell\), esig\(\ell\)(H(Br \(\ell\))), \(\sigma\)r,1 \(\ell\)),b 则 i 集 v′ 我 \(\triangleq\)H(Br \(\ell\));否则我设置 v′ 我\(\triangleq\) \(\bot\)。 3.我计算消息mr,2 我 \(\triangleq\)(ESIGi(v′ i), \(\sigma\)r,2 i ),c 销毁了他的临时密钥 斯克罗,2 i ,然后传播 mr,2 我。 a本质上,用户i私下决定r轮的领导者是用户\(\ell\)。 b再次,玩家\(\ell\)的签名和hashes都已成功验证,并且PAY r \(\ell\) 溴 \(\ell\) 是有效的支付集 回合 r — 尽管我不检查是否 PAY r \(\ell\) 是否为 \(\ell\) 的最大值。 c消息 mr,2 我 表示玩家 i 考虑 v′ i 是下一个块的 hash ,或者考虑下一个 块为空。 17也就是说,所有签名都是正确的,并且该块及其 hash 都是有效的 - 尽管我没有检查 所包含的支付集对于其提议者来说是否是最大的。
步骤3:GC第二步 对每个用户 i \(\in\)PKr−k 的说明:用户 i 一旦他开始他自己的第 r 轮步骤 3 知道 Br−1。 • 用户 i 根据 Br−1 的第三个分量计算 Qr−1 并检查 i \(\in\)SV r,3 或 不。 • 如果i /\(\varepsilon\)SV r,3,则i 立即停止自己执行步骤3。 • 如果i \(\in\)SV r,3,则在等待一段时间t3 \(\triangleq\)t2 + 2\(\lambda\) = 3\(\lambda\) + Λ 后,i 的行为如下。 1. 如果存在一个值 v′ ̸= \(\bot\),使得所有有效消息中 mr,2 j 他已收到, 其中超过 2/3 的形式为 (ESIGj(v′), \(\sigma\)r,2 j ), 没有任何矛盾, a 然后他计算消息 mr,3 我 \(\triangleq\)(ESIGi(v′), \(\sigma\)r,3 我)。否则,他计算 mr,3 我 \(\triangleq\) (ESIGi(\(\bot\)), \(\sigma\)r,3 我)。 2. 我销毁了他的临时密钥 skr,3 i ,然后传播 mr,3 我。 a即他没有收到两条分别包含ESIGj(v′)和不同ESIGj(v′′)的有效消息, 来自玩家 j。从现在开始,除了稍后定义的结束条件外,每当诚实的玩家 想要给定形式的消息,相互矛盾的消息永远不会被计算或被认为是有效的。步骤4:GC的输出和BBA的第一步⋆ 对每个用户 i \(\in\)PKr−k 的说明:用户 i 一旦他开始他自己的第 r 轮步骤 4 知道 Br−1。 • 用户 i 根据 Br−1 的第三个分量计算 Qr−1 并检查 i \(\in\)SV r,4 或 不。 • 如果i /\(\varepsilon\)SV r,4,则i 立即停止自己执行步骤4。 • 如果i \(\in\)SV r,4,则在等待一段时间t4 \(\triangleq\)t3 + 2\(\lambda\) = 5\(\lambda\) + Λ 后,i 的行为如下。 1. 他计算 GC 的输出 vi 和 gi,如下所示。 (a) 如果存在一个值 v′ ̸= \(\bot\),使得在所有有效消息中 mr,3 j 他有 收到的,其中超过 2/3 的形式为 (ESIGj(v′), \(\sigma\)r,3 j ), 然后他设置 vi \(\triangleq\)v′ 和 gi \(\triangleq\)2。 (b) 否则,如果存在一个值 v′ ̸= \(\bot\),使得在所有有效消息中 先生,3 j 他收到的,超过 1/3 的形式是 (ESIGj(v′), \(\sigma\)r,3 j ), 那么 他设置 vi \(\triangleq\)v′ 和 gi \(\triangleq\)1.a (c) 否则,他设置 vi \(\triangleq\)H(Br \(\varepsilon\) ) 和 gi \(\triangleq\)0。 2. 他计算 BBA⋆的输入 bi,如下: 如果 gi = 2,则 bi \(\triangleq\)0,否则 bi \(\triangleq\)1。 3. 他计算消息 mr,4 我 \(\triangleq\)(ESIGi(bi), ESIGi(vi), \(\sigma\)r,4 i ), 毁掉了他短暂的 密钥 skr,4 i ,然后传播 mr,4 我。 a可以证明,情况(b)中的v′如果存在,则必定是唯一的。
步骤 s, 5 \(\leq\)s \(\leq\)m + 2, s −2 ≡0 mod 3:BBA⋆的硬币固定至 0 步骤 对每个用户 i \(\in\)PKr−k 的说明:用户 i 一旦他开始,就开始他自己的第 r 轮步骤 s 知道 Br−1。 • 用户i 根据Br−1 的第三个分量计算Qr−1 并检查i 是否\(\in\)SV r,s。 • 如果i /\(\varepsilon\)SV r,s,则i 立即停止自己执行步骤s。 • 如果i \(\in\)SV r,s 那么他的行为如下。 – 他等待一段时间 ts \(\triangleq\)ts−1 + 2\(\lambda\) = (2s −3)\(\lambda\) + Λ 过去。 – 结束条件 0:如果在等待期间的任意时间点,存在 字符串 v ̸= \(\bot\) 和步骤 s′ 使得 (a) 5 \(\leq\) s′ \(\leq\) s, s′ −2 eq 0 mod 3 — 也就是说,步骤 s′ 是一个 Coin-Fixed-To-0 步骤, (b) i 至少收到了 tH = 2n 3 + 1 条有效消息 mr,s′−1 j = (ESIGj(0), ESIGj(v), \(\sigma\)r,s′−1 j ),a 和 (c) 我收到一条有效消息 mr,1 j = (Br j , esigj(H(Br j )), \(\sigma\)r,1 j ) 其中 v = H(Br j), 然后,我立即停止自己执行步骤 s(实际上是回合 r),而无需 传播任何东西;设 Br = Br j ;并将自己的 CERT r 设置为消息集 mr,s′−1 j 子步骤(b).b – 结束条件 1:如果在等待期间的任意时间点,存在 步骤 s' 使得 (a’) 6 \(\leq\)s′ \(\leq\)s, s′ -2 eq 1 mod 3 — 即,步骤 s′ 是 Coin-Fixed-To-1 步骤,并且 (b’) i 已收到至少 tH 条有效消息 mr,s’−1 j = (ESIGj(1), ESIGj(vj), \(\sigma\)r,s′−1 j ),c 然后,我立即停止自己执行步骤 s(实际上是回合 r),而无需 传播任何东西;设 Br = Br \(\varepsilon\) ;并将自己的 CERT r 设置为消息集 mr,s′−1 j 子步骤(b’)的。 – 否则,在等待结束时,用户 i 执行以下操作。 他将 vi 设置为所有有效投票的第二部分中 vj 的多数票 先生,s−1 j 他已经收到了。 他计算 bi 如下。 如果超过所有有效 mr,s−1 的 2/3 j 他收到的是以下形式的 (ESIGj(0), ESIGj(vj), \(\sigma\)r,s−1 j ),然后他设置 bi \(\triangleq\)0。 否则,如果超过所有有效 mr,s−1 的 2/3 j 他收到的是以下形式的 (ESIGj(1), ESIGj(vj), \(\sigma\)r,s−1 j ),然后他设置 bi \(\triangleq\)1。 否则,他设置 bi \(\triangleq\)0。 他计算了消息 mr,s 我 \(\triangleq\)(ESIGi(bi), ESIGi(vi), \(\sigma\)r,s i ), 毁掉了他短暂的 密钥 skr,s i ,然后传播 mr,s 我。 a 即使玩家 i 也收到了来自 j 的签名为 1 的消息,来自玩家 j 的此类消息也会被计数。 结束条件 1 也有类似的情况。如分析所示,这样做是为了确保所有诚实的用户都知道 Br 彼此相距 \(\lambda\) 时间内。 b 用户 i 现在知道 Br 并且他自己的 r 轮结束。他仍然以普通用户的身份帮助传播消息,但是 不作为 (r, s) 验证者发起任何传播。特别是,他帮助传播了他的所有信息 CERT r,这对于我们的协议来说已经足够了。注意,他还应该为二进制 BA 协议设置 bi \(\triangleq\)0,但是 bi 无论如何,在这种情况下是不需要的。类似的事情适用于所有未来的指示。 c在这种情况下,vj 是什么并不重要。步骤 s, 6 \(\leq\)s \(\leq\)m + 2, s −2 ≡1 mod 3:BBA⋆的硬币固定到 1 步骤 对每个用户 i \(\in\)PKr−k 的说明:用户 i 一旦他开始,就开始他自己的第 r 轮步骤 s 知道 Br−1。 • 用户 i 根据 Br−1 的第三个分量计算 Qr−1 并检查 i 是否 \(\in\)SV r,s 或 不。 • 如果i /\(\varepsilon\)SV r,s,则i 立即停止自己执行步骤s。 • 如果 i \(\in\)SV r,s 那么他执行以下操作。 – 他等待一段时间 ts \(\triangleq\)(2s −3)\(\lambda\) + Λ 过去。 – 结束条件 0:与 Coin-Fixed-To-0 步骤相同的指令。 – 结束条件 1:与 Coin-Fixed-To-0 步骤相同的说明。 – 否则,在等待结束时,用户 i 执行以下操作。 他将 vi 设置为所有有效投票的第二部分中 vj 的多数票 先生,s−1 j 他已经收到了。 他计算 bi 如下。 如果超过所有有效 mr,s−1 的 2/3 j 他收到的是以下形式的 (ESIGj(0), ESIGj(vj), \(\sigma\)r,s−1 j ),然后他设置 bi \(\triangleq\)0。 否则,如果超过所有有效 mr,s−1 的 2/3 j 他收到的是以下形式的 (ESIGj(1), ESIGj(vj), \(\sigma\)r,s−1 j ),然后他设置 bi \(\triangleq\)1。 否则,他设置 bi \(\triangleq\)1。 他计算了消息 mr,s 我 \(\triangleq\)(ESIGi(bi), ESIGi(vi), \(\sigma\)r,s i ), 毁掉了他短暂的 密钥 skr,s i ,然后传播 mr,s 我。
步骤 s, 7 \(\leq\)s \(\leq\)m + 2, s −2 ≡2 mod 3:BBA⋆的硬币真实翻转步骤 对每个用户 i \(\in\)PKr−k 的说明:用户 i 一旦他开始,就开始他自己的第 r 轮步骤 s 知道 Br−1。 • 用户 i 根据 Br−1 的第三个分量计算 Qr−1 并检查 i 是否 \(\in\)SV r,s 或 不。 • 如果i /\(\varepsilon\)SV r,s,则i 立即停止自己执行步骤s。 • 如果 i \(\in\)SV r,s 那么他执行以下操作。 – 他等待一段时间 ts \(\triangleq\)(2s −3)\(\lambda\) + Λ 过去。 – 结束条件 0:与 Coin-Fixed-To-0 步骤相同的指令。 – 结束条件 1:与 Coin-Fixed-To-0 步骤相同的说明。 – 否则,在等待结束时,用户 i 执行以下操作。 他将 vi 设置为所有有效投票的第二部分中 vj 的多数票 先生,s−1 j 他已经收到了。 他计算 bi 如下。 如果超过所有有效 mr,s−1 的 2/3 j 他收到的是以下形式的 (ESIGj(0), ESIGj(vj), \(\sigma\)r,s−1 j ),然后他设置 bi \(\triangleq\)0。 否则,如果超过所有有效 mr,s−1 的 2/3 j 他收到的是以下形式的 (ESIGj(1), ESIGj(vj), \(\sigma\)r,s−1 j ),然后他设置 bi \(\triangleq\)1。 否则,令 SV r,s−1 我 是(r,s -1)验证者的集合,他从这些验证者那里收到了有效的 消息 mr,s−1 j 。他设置 bi \(\triangleq\)lsb(minj\(\in\)SV r,s−1 我 H(\(\sigma\)r,s−1 j ))。 他计算了消息 mr,s 我 \(\triangleq\)(ESIGi(bi), ESIGi(vi), \(\sigma\)r,s i ), 毁掉了他短暂的 密钥 skr,s i ,然后传播 mr,s 我。
步骤 m + 3:BBA⋆a的最后一步 对每个用户 i \(\in\)PKr−k 的说明:用户 i 一旦他开始他自己的第 r 轮步骤 m + 3 知道 Br−1。 • 用户 i 根据 Br−1 的第三个分量计算 Qr−1 并检查 i \(\in\)SV r,m+3 或 不。 • 如果i /\(\varepsilon\)SV r,m+3,则i 立即停止自己执行步骤m+3。 • 如果 i \(\in\)SV r,m+3 那么他执行以下操作。 – 他等待一段时间 tm+3 \(\triangleq\)tm+2 + 2\(\lambda\) = (2m + 3)\(\lambda\) + Λ 过去。 – 结束条件 0:与 Coin-Fixed-To-0 步骤相同的指令。 – 结束条件 1:与 Coin-Fixed-To-0 步骤相同的说明。 – 否则,在等待结束时,用户 i 执行以下操作。 他设置了 i \(\triangleq\)1 和 Br \(\triangleq\)Br ǫ。 他计算消息 mr,m+3 我 = (ESIGi(outi), ESIGi(H(Br)), \(\sigma\)r,m+3 我 ),毁了他的 临时密钥 skr,m+3 我 ,然后传播 mr,m+3 我 证明 Br.b a极有可能 BBA⋆在此步骤之前已结束,为了完整性,我们指定此步骤。 b 步骤 m + 3 中的证书不必包含 ESIGi(outi)。我们将其包含在内只是为了统一: 现在,无论在哪个步骤生成证书,它们都具有统一的格式。非验证者重建 Round-r 区块 系统中每个用户 i 的说明: 用户 i 一旦知道就开始自己的回合 r Br−1,并等待块信息如下。 – 如果在这样的等待期间和任何时间点,存在一个字符串 v 和一个步骤 s′,这样 那个 (a) 5 \(\leq\) s′ \(\leq\) m + 3 其中 s′ −2 ≡0 mod 3, (b) i 已收到至少 tH 条有效消息 mr,s′−1 j = (ESIGj(0), ESIGj(v), \(\sigma\)r,s′−1 j ),以及 (c) 我收到一条有效消息 mr,1 j = (Br j , esigj(H(Br j )), \(\sigma\)r,1 j ) 其中 v = H(Br j), 然后,i立即停止自己执行r轮;设 Br = Br j;并设置了自己的 CERT r 是消息集 mr,s′−1 j 子步骤(b)的。 – 如果在等待期间的任意时间点,存在步骤 s',使得 (a’) 6 \(\leq\)s′ \(\leq\)m + 3 其中 s′ -2 ≡1 mod 3,并且 (b’) i 已收到至少 tH 条有效消息 mr,s’−1 j = (ESIGj(1), ESIGj(vj), \(\sigma\)r,s′−1 j ), 然后,i立即停止自己执行r轮;设 Br = Br ǫ;并设置了自己的 CERT r 是消息集 mr,s′−1 j 子步骤(b’)的。 – 如果在等待期间的任何时间点,i 至少收到了 tH 条有效消息 先生,米+3 j = (ESIGj(1), ESIGj(H(Br \(\varepsilon\) )), \(\sigma\)r,m+3 j ),然后我停止自己执行 r 轮 立即设置 Br = Br ϫ ,并将自己的 CERT r 设置为消息集 mr,m+3 j 为 1 和 H(Br )。 5.5 Algorand ' 的分析 1 我们为分析中使用的每轮 r \(\geq\) 0 引入以下符号。 • 令Tr 为第一个诚实用户知道Br−1 的时间。 • 设Ir+1 为区间[T r+1, T r+1 + \(\lambda\)]。 注意协议初始化时T 0 = 0。对于每个 s \(\geq\)1 且 i \(\in\)SV r,s,回想一下 \(\alpha\)r,s 我 和 \(\beta\)r,s 我 分别是玩家i的步骤s的开始时间和结束时间。而且, 回想一下,对于每个 2 \(\leq\) s \(\leq\) m + 3,ts = (2s −3)\(\lambda\) + Λ。此外,令 I0 \(\triangleq\){0} 且 t1 \(\triangleq\)0。 最后,回想一下 Lr \(\leq\)m/3 是代表伯努利试验次数的随机变量 需要看到 1,当每次试验都是 1 的概率 ph 2 并且最多有 m/3 次试验。如果全部 试验失败则 Lr \(\triangleq\)m/3。 在分析中我们忽略计算时间,因为它实际上相对于所需的时间可以忽略不计 来传播消息。无论如何,通过使用稍大的 \(\lambda\) 和 Λ,计算时间可以 直接纳入分析。下面的大多数陈述都“压倒性地” 概率”,我们在分析中可能不会反复强调这一事实。5.6 主要定理 定理 5.1。对于每轮 r \(\geq\)0,以下属性以压倒性的概率成立: 1. 所有诚实的用户都同意同一个区块 Br。 2. 当领导者 \(\ell\)r 诚实时,区块 Br 由 \(\ell\)r 生成,Br 包含最大支付集 \(\ell\)r 在时间 \(\alpha\)r,1 收到 \(\ell\)r , T r+1 \(\leq\)T r + 8\(\lambda\) + Λ 并且所有诚实用户此时都知道 Br 间隔Ir+1。 3. 当领导者 \(\ell\)r 恶意时,T r+1 \(\leq\)T r + (6Lr + 10)\(\lambda\) + Λ 并且所有诚实用户都知道 Br 在时间间隔Ir+1内。 4. Lr 的 ph = h2(1 + h −h2),并且领导者 \(\ell\)r 是诚实的,概率至少为 ph。 在证明我们的主要定理之前,让我们先说两点。 评论。 • 块生成和真实延迟。生成块Br的时间定义为T r+1 −T r。 也就是说,它被定义为某个诚实用户第一次学习 Br 和 一些诚实的用户第一次学习 Br−1。当 R 轮领导者诚实时,我们的属性 2 主定理保证生成 Br 的准确时间是 8\(\lambda\) + Λ 时间,无论怎样 h > 2/3 的精确值可能是。当领导者恶意时,性质 3 意味着 生成 Br 的预期时间上限为 ( 12 ph + 10)\(\lambda\) + Λ,同样无论精确度如何 h.18 的值 然而,生成 Br 的预期时间取决于 h 的精确值。 事实上,根据性质 4,ph = h2(1 + h −h2) 并且领导者至少有概率是诚实的 ph,因此 E[T r+1 −T r] \(\leq\)h2(1 + h −h2) \(\cdot\) (8\(\lambda\) + Λ) + (1 −h2(1 + h −h2))(( 12 h2(1 + h −h2) + 10)\(\lambda\) + Λ)。 例如,如果 h = 80%,则 E[T r+1 -T r] \(\leq\)12.7\(\lambda\) + Λ。 • \(\lambda\) 与Λ。请注意,验证者在步骤 Algorand ' 中发送的消息的大小是主导的 通过数字签名密钥的长度,即使数字签名密钥的数量可以保持固定, 用户数量巨大。另请注意,在任何步骤 s > 1 中,验证者的预期数量 n 相同 无论用户数是100K、100M、100M都可以使用。之所以如此,是因为 n 仅 取决于 h 和 F。因此,总而言之,除非突然需要增加密钥长度, 无论用户数量有多大,\(\lambda\) 的值都应该保持不变 可预见的未来。 相比之下,对于任何交易率,交易数量随着交易数量的增加而增长。 用户。因此,为了及时处理所有新交易,块的大小应该 也随着用户数量的增长而增长,导致 Λ 也增长。因此,从长远来看,我们应该 \(\lambda\) << Λ。因此, \(\lambda\) 的系数宜取较大,实际上是一个系数 Λ 为 1。 定理 5.1 的证明。我们通过归纳法证明性质 1-3:假设它们在 r −1 轮中成立 (不失一般性,当 r = 0 时,它们自动成立“round -1”),我们证明它们 朗德河 18确实,E[T r+1 −T r] \(\leq\)(6E[Lr] + 10)\(\lambda\) + Λ = (6 \(\cdot\) 2 ph + 10)\(\lambda\) + Λ = ( 12 ph + 10)\(\lambda\) + Λ。由于 Br−1 由归纳假设唯一定义,因此集合 SV r,s 被唯一定义 对于第 r 轮的每个步骤 s。通过n1的选择,SV r,1 ̸=\(\emptyset\)以压倒性的概率。我们现在 陈述以下两个引理,在第 5.7 节和第 5.8 节中证明。在整个归纳过程中 两个引理的证明,第0轮的分析几乎与归纳步骤相同, 当差异发生时我们会强调它们。 引理 5.2。 [完整性引理] 假设属性 1-3 在 r−1 轮中成立,当领导者 \(\ell\)r 是诚实的,具有压倒性的概率, • 所有诚实的用户都同意同一个区块 Br,该区块由 \(\ell\)r 生成并包含最大 \(\ell\)r 在时间 \(\alpha\)r,1 收到的付款集 \(\ell\)r \(\in\)Ir;和 • T r+1 \(\leq\)T r + 8\(\lambda\) + Λ 并且所有诚实用户在时间间隔Ir+1 内都知道Br。 引理 5.3。 [健全性引理] 假设属性 1-3 在 r -1 轮中成立,当领导者 \(\ell\)r 是恶意的,以压倒性的概率,所有诚实用户都同意同一个区块 Br,T r+1 \(\leq\) T r + (6Lr + 10)\(\lambda\) + Λ 并且所有诚实用户在时间间隔 Ir+1 内都知道 Br。 通过将引理 5.2 和 5.3 应用于 r = 0 和归纳步骤,性质 1-3 成立。最后, 我们将性质 4 重述为以下引理,并在第 5.9 节中证明。 引理 5.4。给定 r 之前每一轮的属性 1-3,Lr 的 ph = h2(1 + h −h2),并且 领导者 \(\ell\)r 是诚实的,概率至少为 ph。 将以上三个引理结合在一起,定理 5.1 成立。 ■ 下面的引理陈述了关于 r 轮的几个重要属性,给定电感 假设,并将用于上述三个引理的证明。 引理 5.5。假设属性 1-3 对于 r -1 轮成立。对于第 r 轮的每个步骤 s \(\geq\)1 且 每个诚实的验证者 i \(\in\) HSV r,s,我们有 (a) \(\alpha\)r,s 我 \(\varepsilon\)Ir; (b) 如果玩家 i 等待了一段时间 ts,则 \(\beta\)r,s 我 \(\varepsilon\)[T r + ts, T r + \(\lambda\) + ts] 对于 r > 0 且 \(\beta\)r,s 我 = ts,r = 0;和 (c) 如果玩家 i 等待了时间 ts,则到时间 \(\beta\)r,s 我,他已收到所有消息 由所有诚实验证者发送 j \(\in\)HSV r,s′ 对于所有步骤 s′ < s。 此外,对于每个步骤 s \(\geq\)3,我们有 (d) 不存在两个不同的参与者 i, i′ \(\in\)SV r,s 以及相同的两个不同的值 v, v′ 长度,使得两个玩家都等待了一定时间 ts,超过所有玩家的 2/3 有效消息 mr,s−1 j i 收到的玩家已经为 v 签名,且超过所有有效玩家的 2/3 消息 mr,s−1 j 球员 i′ 收到 v′ 的签名。 证明。性质 (a) 直接从归纳假设得出,因为玩家 i 知道 Br−1 时间间隔 Ir 并立即开始自己的步骤 s。性质 (b) 直接从 (a) 得出:因为 玩家 i 在行动之前等待了一段时间 ts,\(\beta\)r,s 我 = \(\alpha\)r,s 我 + ts。注意 \(\alpha\)r,s 我 = 0 为 r = 0。 我们现在证明性质(c)。如果 s = 2,则根据性质 (b),对于所有验证者 j \(\in\) HSV r,1 我们有 \(\beta\)r,s 我 = \(\alpha\)r,s 我 + ts \(\geq\)T r + ts = T r + \(\lambda\) + Λ \(\geq\) \(\beta\)r,1 j + Λ。由于每个验证者 j \(\in\)HSV r,1 在时间 \(\beta\)r,1 发送他的消息 j 并且消息到达所有诚实的人 最多 Λ 时间内的用户,时间为 \(\beta\)r,s 我 玩家 i 已收到所有验证者发送的消息 HSV r,1 根据需要。 如果 s > 2,则 ts = ts−1 + 2\(\lambda\)。根据性质 (b),对于所有步骤 s′ < s 且所有验证者 j \(\in\) HSV r,s′, \(\beta\)r,s 我 = \(\alpha\)r,s 我 + ts \(\geq\)T r + ts = T r + ts−1 + 2\(\lambda\) \(\geq\)T r + ts′ + 2\(\lambda\) = T r + \(\lambda\) + ts′ + \(\lambda\) \(\geq\) \(\beta\)r,s′ j + \(\lambda\)。 由于每个验证者 j \(\in\)HSV r,s′ 在时间 \(\beta\)r,s′ 发送他的消息 j 并且消息到达所有诚实的人 最多 \(\lambda\) 时间内的用户,到时间 \(\beta\)r,s 我 玩家 i 已收到所有诚实验证者发送的所有消息 在 HSV r,s' 中,对于所有 s' < s。因此性质(c)成立。 最后,我们证明性质(d)。请注意,验证者 j \(\in\)SV r,s−1 最多签署两个东西 步骤 s -1 使用它们的临时密钥:与输出相同长度的值 vj hash 函数,如果 s −1 \(\geq\)4,则还有一点 bj \(\in\){0, 1}。这就是为什么在引理的陈述中 我们要求 v 和 v′ 具有相同的长度:许多验证者可能都签署了 hash 值 v 和位 b,因此都通过了 2/3 阈值。 为了矛盾起见,假设存在所需的验证者 i、i′ 和值 v、v′。 请注意,MSV r,s−1 中的一些恶意验证者可能同时签署了 v 和 v′,但每个诚实的验证者 HSV r,s−1 中的验证者最多签署了其中一个。根据性质 (c),i 和 i′ 均已收到 HSV r,s−1 中所有诚实验证者发送的所有消息。 令 HSV r,s−1(v) 为已签署 v、MSV r,s−1 的诚实 (r, s −1) 验证者集合 我 集合 i 收到有效消息的恶意 (r, s −1) 验证者的数量,以及 MSV r,s−1 我 (五) MSV r,s−1 的子集 我 我从谁那里收到了有效的消息签名 v. 根据以下要求 i 和 v,我们有 比率 \(\triangleq\)|HSV r,s−1(v)| + |MSV r,s−1 我 (五)| |HSV r,s−1| + |MSV r,s−1 我 |
2 3. (1) 我们首先展示 |MSV r,s−1 我 (五)| \(\leq\)|HSV r,s−1(v)|。 (2) 否则,根据参数之间的关系,以压倒性的概率 |HSV r,s−1| > 2|MSV r,s−1| \(\geq\)2|MSV r,s−1 我 |,因此 比率 < |HSV r,s−1(v)| + |MSV r,s−1 我 (五)| 3|MSV r,s−1 我 | < 2|MSV r,s−1 我 (五)| 3|MSV r,s−1 我 | \(\leq\)2 3、 矛盾不等式 1. 接下来,根据不等式 1 我们有 2|HSV r,s−1| + 2|MSV r,s−1 我 | < 3|HSV r,s−1(v)| + 3|MSV r,s−1 我 (五)| \(\leq\) 3|HSV r,s−1(v)| + 2|MSV r,s−1 我 | + |MSV r,s−1 我 (五)|。 结合不等式2, 2|HSV r,s−1| < 3|HSV r,s−1(v)| + |MSV r,s−1 我 (五)| \(\leq\)4|HSV r,s−1(v)|, 这意味着 |HSV r,s−1(v)| > 1 2|HSV r,s−1|。类似地,根据 i′ 和 v′ 的要求,我们有 |HSV r,s−1(v′)| > 1 2|HSV r,s−1|。 由于诚实的验证者 j \(\in\)HSV r,s−1 破坏了他的临时密钥 skr,s−1 j 传播前 在他的消息中,攻击者无法伪造 j 的签名以获得 j 未签名的值,之后 得知 j 是验证者。因此,上面的两个不等式意味着 |HSV r,s−1| \(\geq\)|HSV r,s−1(v)| + |HSV r,s−1(v′)| > |HSV r,s−1|,矛盾。因此,所需的 i、i'、v、v' 不存在,并且 性质 (d) 成立。 ■ 5.7 完整性引理 引理 5.2。 [完整性引理,重述] 假设属性 1-3 对于 r−1 轮成立,当 领导者 \(\ell\)r 是诚实的,有压倒性的概率, • 所有诚实的用户都同意同一个区块 Br,该区块由 \(\ell\)r 生成并包含最大 \(\ell\)r 在时间 \(\alpha\)r,1 收到的付款集 \(\ell\)r \(\in\)Ir;和 • T r+1 \(\leq\)T r + 8\(\lambda\) + Λ 并且所有诚实用户在时间间隔Ir+1 内都知道Br。 证明。根据归纳假设和引理 5.5,对于每个步骤 s 和验证器 i \(\in\) HSV r,s, \(\alpha\)r,s 我 \(\varepsilon\)Ir。下面我们一步步分析该协议。 步骤1。 根据定义,每个诚实验证者 i \(\in\) HSV r,1 传播所需的消息 mr,1 我 在 时间\(\beta\)r,1 我 =\(\alpha\)r,1 我 ,其中 mr,1 我 = (Br i , esigi(H(Br i )), \(\sigma\)r,1 i ), Br 我 = (r, 支付 r i , SIGi(Qr−1), H(Br−1)), 并支付 i 是我在时间 \(\alpha\)r,1 之前看到的所有付款中的最大付款集 我。 步骤2。 任意固定一个诚实验证者 i \(\in\) HSV r,2。根据引理 5.5,当玩家 i 完成时 在时间 \(\beta\)r,2 等待 我 =\(\alpha\)r,2 我 + t2,他已经收到HSV r,1中验证者发送的所有消息,包括 先生,1 \(\ell\)r 。根据 \(\ell\)r 的定义,PKr−k 中不存在其凭证为 hash 的其他玩家 值小于 H(\(\sigma\)r,1 \(\ell\)r)。当然,对手在看到 H(\(\sigma\)r,1 \(\ell\)r) 非常小,但那时玩家 \(\ell\)r 已经销毁了他的临时密钥和消息 mr,1 \(\ell\)r 已被传播。因此验证者 i 将自己的领导者设置为玩家 \(\ell\)r。因此,在时间 \(\beta\)r,2 我, 验证者 i 传播 mr,2 我 = (ESIGi(v′ i), \(\sigma\)r,2 i ), 其中 v′ 我 = H(Br \(\ell\)r)。当 r = 0 时,唯一的区别 是 \(\beta\)r,2 我 = t2 而不是在一个范围内。对于未来的步骤也可以说类似的话,我们 不会再强调它们。 步骤 3. 任意固定一个诚实验证者 i \(\in\) HSV r,3。根据引理 5.5,当玩家 i 完成时 在时间 \(\beta\)r,3 等待 我 =\(\alpha\)r,3 我 + t3,他已收到 HSV r,2 中验证者发送的所有消息。 通过参数之间的关系,以压倒性的概率 |HSV r,2| > 2|MSV r,2|。此外,没有诚实的验证者会签署相互矛盾的消息,而对手 在诚实验证者销毁其对应的签名后,无法伪造该签名 临时密钥。因此,我收到的所有有效 (r, 2) 消息中超过 2/3 来自 诚实的验证者,形式为 mr,2 j = (ESIGj(H(Br \(\ell\)r)), \(\sigma\)r,2 j ), 不矛盾。 因此,在时间 \(\beta\)r,3 我 玩家 i 传播 mr,3 我 = (ESIGi(v′), \(\sigma\)r,3 i ), 其中 v′ = H(Br \(\ell\)r)。步骤 4。 任意固定一个诚实验证者 i \(\in\) HSV r,4。根据引理 5.5,玩家 i 已收到所有 当 HSV r,3 中的验证者在时间 \(\beta\)r,4 完成等待时发送的消息 我 =\(\alpha\)r,4 我 + t4。类似于 步骤 3,i 收到的所有有效 (r, 3) 消息中超过 2/3 来自诚实的验证者,并且 mr,3 形式的 j = (ESIGj(H(Br \(\ell\)r)), \(\sigma\)r,3 j)。 因此,玩家 i 设置 vi = H(Br \(\ell\)r), gi = 2 且 bi = 0。在时间 \(\beta\)r,4 我 =\(\alpha\)r,4 我 +t4 他传播 先生,4 我 = (ESIGi(0), ESIGi(H(Br \(\ell\)r)), \(\sigma\)r,4 我)。 步骤 5。 任意固定一个诚实验证者 i \(\in\) HSV r,5。 根据引理 5.5,我将拥有的玩家 如果他一直等到时间 \(\alpha\)r,5,则接收到 HSV r,4 中验证者发送的所有消息 我 + t5。请注意 |HSV r,4| \(\geq\)tH.19 另请注意,HSV r,4 中的所有验证者均已签署 H(Br \(\ell\)r)。 作为 |MSV r,4| < tH,不存在任何 v′ ̸= H(Br \(\ell\)r) 可能由 tH 签署 SV r,4 中的验证者(必然是恶意的),因此玩家 i 在他完成之前不会停止 收到了 tH 个有效消息 mr,4 j = (ESIGj(0), ESIGj(H(Br \(\ell\)r)), \(\sigma\)r,4 j)。设 T 为时间 后一个事件发生。其中一些消息可能来自恶意玩家,但因为 |MSV r,4| < tH,其中至少有一个来自 HSV r,4 中的诚实验证者,并且在时间之后发送 Tr+t4。因此,T \(\geq\)T r +t4 > T r +\(\lambda\)+Λ \(\geq\) \(\beta\)r,1 \(\ell\)r +Λ,到时间 T 时,玩家 i 也收到了 消息先生,1 \(\ell\)r 。通过构建协议,玩家 i 在时间 \(\beta\)r,5 处停止 我 = T 无 传播任何东西;设 Br = Br \(\ell\)r;并将他自己的 CERT r 设置为 (r, 4) 消息的集合 0 和 H(Br \(\ell\)r) 他已经收到了。 步骤 s > 5。 类似地,对于任何步骤 s > 5 和任何验证者 i \(\in\) HSV r,s,玩家 i 将有 如果他一直等到时间 \(\alpha\)r,s,则接收到 HSV r,4 中验证者发送的所有消息 我 + ts。由 同样的分析,玩家 i 停止而不传播任何内容,设置 Br = Br \(\ell\)r(并设置自己的 CERT 正确)。当然,恶意验证者可能不会停止,并且可能会任意传播 消息,但因为 |MSV r,s| < tH,通过归纳,tH 验证者无法签署其他 v′ 在任何步骤 4 \(\leq\) s′ < s 中,因此诚实的验证者只会停止,因为他们已经收到了有效的 tH (r, 4)-0 和 H(Br \(\ell\)r)。 Round-r 街区的重建。 第 5 步的分析适用于一般诚实 用户 i 几乎没有任何变化。事实上,玩家 i 在间隔 Ir 中开始自己的回合 r,并且 仅当他收到 H(Br) 的 tH 个有效 (r, 4) 消息时,才会在时间 T 停止 \(\ell\)r)。再次因为 这些消息中至少有一条来自诚实的验证者,并且在时间 T r + t4 之后发送,玩家 i 有 还收到了 Mr,1 \(\ell\)r 到时间 T。因此他设置 Br = Br \(\ell\)r 与适当的 CERT r。 剩下的只是证明所有诚实用户在时间间隔 Ir+1 内完成他们的 r 轮。 通过第 5 步的分析,每个诚实验证者 i \(\in\)HSV r,5 都知道 \(\alpha\)r,5 上或之前的 Br 我 + t5 \(\leq\) Tr + \(\lambda\) + t5 = Tr + 8\(\lambda\) + Λ。由于 T r+1 是第一个诚实用户 ir 知道 Br 的时间,所以我们有 T r+1 \(\leq\)T r + 8\(\lambda\) + Λ 根据需要。而且,当玩家ir认识Br时,他已经帮助传播了信息 他的 CERT r。请注意,所有这些消息都将在时间 \(\lambda\) 内被所有诚实的用户收到,即使 19严格来说,这种情况发生的可能性非常高,但不一定是压倒性的。 然而,这 概率稍微影响协议的运行时间,但不影响其正确性。当h=80%时,则 |HSV r,4| \(\geq\)tH 的概率为 1 −10−8。如果此事件没有发生,则协议将继续进行另一个事件 3 个步骤。由于这种情况在两个步骤中不发生的概率可以忽略不计,因此协议将在步骤 8 结束。 期望的话,需要的步数差不多是5。玩家 ir 是第一个传播它们的玩家。此外,根据上面的分析我们有 T r+1 \(\geq\)T r + t4 \(\geq\) \(\beta\)r,1 \(\ell\)r + Λ,因此所有诚实用户都收到了 mr,1 \(\ell\)r 乘以时间 T r+1 + \(\lambda\)。据此, 所有诚实的用户都知道时间间隔 Ir+1 = [T r+1, T r+1 + \(\lambda\)] 内的 Br。 最后,对于 r = 0,我们实际上有 T 1 \(\leq\)t4 + \(\lambda\) = 6\(\lambda\) + Λ。将一切结合在一起, 引理 5.2 成立。 ■ 5.8 健全性引理 引理 5.3。 [可靠性引理,重述] 假设属性 1-3 对于 r -1 轮成立,当 领导者\(\ell\)r是恶意的,以压倒性的概率,所有诚实的用户都同意同一个区块 Br,T r+1 \(\leq\)T r + (6Lr + 10)\(\lambda\) + Λ 并且所有诚实用户在时间间隔 Ir+1 内都知道 Br。 证明。我们分别考虑协议的两个部分,GC 和 BBA⋆。 GC。 根据归纳假设和引理 5.5,对于任何步骤 s \(\in\){2, 3, 4} 和任何诚实的 验证者 i \(\in\) HSV r,s,当玩家 i 在时间 \(\beta\)r,s 行动时 我 = \(\alpha\)r,s 我 + ts,他已收到所有发送的消息 由所有诚实的验证者在步骤 s' < s 中进行验证。我们在步骤 4 中区分了两种可能的情况。 情况 1. 没有验证者 i \(\in\) HSV r,4 设置 gi = 2。 在这种情况下,根据定义,对于所有验证者 i \(\in\) HSV r,4,bi = 1。也就是说,他们从一个 就二进制 BA 协议中的 1 达成一致。他们可能没有就他们的 vi 达成一致, 但这并不重要,正如我们将在二进制 BA 中看到的那样。 情况 2. 存在一个验证器 ˆi \(\in\)HSV r,4 使得 gˆi = 2。 在这种情况下,我们表明 (1) 对于所有 i \(\in\)HSV r,4,gi \(\geq\)1, (2) 存在一个值 v′,使得 vi = v′ 对于所有 i \(\in\)HSV r,4,并且 (3) 存在有效消息 mr,1 \(\ell\) 来自一些验证者 \(\ell\) \(\in\)SV r,1 使得 v′ = H(Br \(\ell\))。 事实上,由于玩家 ˆi 是诚实的并且设置 gˆi = 2,所以超过所有有效消息的 2/3 mr,3 j 他收到了相同的值 v′ ̸= \(\bot\),并且他设置了 vˆi = v′。 根据引理 5.5 中的性质 (d),对于任何其他诚实的 (r, 4) 验证者 i,它不可能比 超过所有有效消息的 2/3 mr,3 j i′ 收到的值具有相同的值 v′′ ̸= v′。 因此,如果 i 设置 gi = 2,则 i 也必须看到 v′ 的多数票数 > 2/3,并且设置 vi = v′,根据需要。 现在考虑任意验证者 i \(\in\) HSV r,4 且 gi < 2。与 Property 的分析类似 (d) 在引理 5.5 中,因为玩家 ˆi 已经看到 v′ 超过 2/3 多数,超过 1 2|HSV r,3|诚实的 (r, 3)-验证者已签署 v′。因为我已经收到了诚实的 (r, 3) 验证者的所有消息 时间\(\beta\)r,4 我 =\(\alpha\)r,4 我 + t4,他特别收到了超过 1 2|HSV r,3|来自他们的消息 对于 v′。因为 |HSV r,3| > 2|MSV r,3|, i 看到 v′ 占 > 1/3 多数。据此,玩家 i 设 gi = 1,且性质 (1) 成立。 玩家 i 是否一定设置 vi = v′?假设存在一个不同的值 v′′ ̸= \(\bot\),使得 玩家 i 也看到 v′′ 的投票率超过 1/3。其中一些消息可能来自恶意 验证者,但至少其中一个来自某个诚实的验证者 j \(\in\)HSV r,3:确实,因为 |HSV r,3| > 2|MSV r,3|我已收到来自 HSV r,3(一组恶意软件)的所有消息 我收到有效 (r, 3) 消息的验证者占所有有效消息的 < 1/3 他收到的消息。根据定义,玩家 j 必须在所有有效 (r, 2) 消息中看到超过 2/3 的 v′′ 消息 他已经收到了。然而,我们已经发现其他一些诚实的 (r, 3) 验证者已经看到 v′ 的 2/3 多数(因为他们签署了 v′)。根据引理 5.5 的性质 (d),这不能 发生并且这样的值 v'' 不存在。因此玩家 i 必须根据需要设置 vi = v′, 且性质(2)成立。 最后,考虑到一些诚实的 (r, 3) 验证者已经看到超过 2/3 的大多数 v',一些(实际上, 超过一半的)诚实的(r,2)验证者已经签署了 v' 并传播了他们的消息。 通过构建协议,那些诚实的 (r, 2) 验证者必须收到有效的 留言先生,1 \(\ell\) 来自某个玩家 \(\ell\) \(\varepsilon\)SV r,1 且 v′ = H(Br \(\ell\)),因此性质(3)成立。 BBA⋆。 我们再次区分两种情况。 情况 1. 所有验证者 i \(\in\) HSV r,4 都有 bi = 1。 这发生在 GC 的情况 1 之后。作为 |MSV r,4| < tH,在这种情况下 SV r,5 中没有验证器 可以收集或生成位 0 的有效 (r, 4) 消息。因此,HSV r,5 中没有诚实的验证者 会停下来,因为他知道一个非空块 Br。 此外,虽然位 1 至少有 tH 个有效 (r, 4) 消息,但 s′ = 5 不满足 s′ −2 ≡1 mod 3,因此 HSV r,5 中没有诚实的验证者会停止,因为他知道 Br = Br ǫ。 相反,每个验证者 i \(\in\) HSV r,5 在时间 \(\beta\)r,5 起作用 我 =\(\alpha\)r,5 我 + t5,当他收到所有 由 HSV r,4 发送的消息遵循引理 5.5。因此,玩家 i 看到 1 的票数超过 2/3 并设置 bi = 1。 在步骤 6 中,这是一个 Coin-Fixed-To-1 步骤,虽然 s′ = 5 满足 s′ −2 ≡0 mod 3,但有 不存在位 0 的有效 (r, 4) 消息,因此 HSV r,6 中的验证器不会停止,因为 他知道一个非空块 Br。然而,当 s′ = 6 时,s′ −2 ≡1 mod 3 且确实存在 |HSV r,5| \(\geq\)tH 来自 HSV r,5 的位 1 的有效 (r, 5) 消息。 对于每个验证者 i \(\in\) HSV r,6,遵循引理 5.5,在时间 \(\alpha\)r,6 或之前 我 + t6 玩家我 已收到来自 HSV r,5 的所有消息,因此我停止传播任何内容并设置 溴 = 溴 ǫ。他的 CERT r 是第 tH 个有效 (r, 5) 消息 mr,5 的集合 j = (ESIGj(1), ESIGj(vj), \(\sigma\)r,5 j) 当他停下来时,他收到了。 接下来,让玩家 i 成为步骤 s > 6 中的诚实验证者或一般诚实用户(即, 非验证者)。类似于引理5.2的证明,玩家i设置Br = Br ǫ 并设定了自己的 CERT r 是 tH 个有效 (r, 5) 消息 mr,5 的集合 j = (ESIGj(1), ESIGj(vj), \(\sigma\)r,5 j) 他有 收到。 最后,与引理 5.2 类似, Tr+1\(\leq\) 分钟 i\(\in\)HSV r,6 \(\alpha\)r,6 我 + t6 \(\leq\) T r + \(\lambda\) + t6 = T r + 10\(\lambda\) + Λ, 并且所有诚实用户在时间间隔 Ir+1 内都知道 Br,因为第一个诚实用户 i 知道 Br 帮助在他的 CERT r 中传播 (r, 5) 消息。 情况 2. 存在一个验证者 ˆi \(\in\)HSV r,4 且 bˆi = 0。 这种情况发生在 GC 的情况 2 之后,并且是更复杂的情况。通过GC分析, 在这种情况下,存在有效消息 mr,1 \(\ell\) 使得 vi = H(Br \(\ell\)) 对于所有 i \(\in\) HSV r,4。注意事项 HSV r,4 中的验证者可能无法就他们的 bi 达成一致。 对于任何步骤 s \(\in\){5, . 。 。 , m + 3} 且验证者 i \(\in\)HSV r,s,根据引理 5.5 玩家 i 将有 收到 HSV r,4 中所有诚实验证者发送的所有消息 \(\cup\) \(\cdots\) \(\cup\)HSV r,s−1 如果他已经等待 时间 ts。我们现在考虑以下事件 E:存在一个步骤 s\(\geq\)5,使得对于第一个 在二进制 BA 中的时间,某个玩家 i\(\in\)SV r,s(无论是恶意的还是诚实的)应该停止 不传播任何东西。我们使用“应该停止”来强调这样一个事实:如果玩家 i 是恶意的,那么他可能会假装按照协议他不应该停止,并且 传播对手选择的消息。 此外,通过协议的构建, (E.a) i能够收集或生成至少 tH 个有效消息 mr,s′−1 j = (ESIGj(0), ESIGj(v), \(\sigma\)r,s′−1 j ) 对于相同的 v 和 s′,其中 5 \(\leq\) s′ \(\leq\) s 且 s′ −2 ≡0 mod 3;或 (E.b) i 能够收集或生成至少 tH 个有效消息 mr,s′−1 j = (ESIGj(1), ESIGj(vj), \(\sigma\)r,s′−1 j ) 对于相同的 s′,其中 6 \(\leq\) s′ \(\leq\) s 且 s′ −2 ≡1 mod 3。 因为诚实的 (r, s' -1) 消息在被发送之前被所有诚实的 (r, s') 验证者接收到。 在步骤 s' 中完成等待,并且因为对手在不迟于 诚实的用户,不失一般性,我们有 s′ = s 并且玩家 i 是恶意的。请注意 我们不要求 E.a 中的值 v 是有效块的 hash :这一点将会变得清楚 分析中,v = H(Br \(\ell\))在此子事件中。 下面我们首先分析事件E之后的情况2,然后表明s的值本质上是 根据 Lr 进行分配(因此事件 E 发生在步骤 m + 3 之前,具有压倒性的优势) 给定参数关系的概率)。首先,对于任何步骤 5 \(\leq\)s < s, 每个诚实的验证者 i \(\in\) HSV r,s 都等待时间 ts 并设置 vi 为大多数投票者 他收到的有效 (r, s−1) 消息。由于玩家 i 已收到所有诚实的 (r, s−1) 消息 遵循引理 5.5,因为 HSV r,4 中的所有诚实验证者都签署了 H(Br \(\ell\)) 以下案例 GC 的 2,并且由于 |HSV r,s−1| > 2|MSV r,s−1|对于每个 s,通过归纳我们有该玩家 i 已设定 vi = H(Br \(\ell\))。 这同样适用于每个诚实的验证者 i \(\in\) HSV r,s,他们不会在不传播的情况下停止 任何东西。现在我们考虑步骤 s 并区分四个子情况。 案例 2.1.a.事件 E.a 发生并且存在一个诚实的验证者 i′ \(\in\)HSV r,s 谁应该 也停止不传播任何东西。 在这种情况下,我们有 s−2 ≡0 mod 3 并且步骤 s 是一个 Coin-Fixed-To-0 步骤。 由 定义,玩家 i′ 已收到至少 tH 条有效的 (r, s−1) 消息,其形式为 (ESIGj(0), ESIGj(v), \(\sigma\)r,s−1 j )。由于 HSV r,s−1 中的所有验证者都签署了 H(Br \(\ell\)) 和 |MSV r,s−1| < tH,我们有 v = H(Br \(\ell\))。 因为至少 tH −|MSV r,s−1| i′ 收到的 0 和 v 的 (r, s−1) 消息中的 \(\geq\)1 条 由 HSV r,s−1 中的验证者在时间 T r +ts−1 \(\geq\)T r +t4 \(\geq\)T r +\(\lambda\)+Λ \(\geq\) \(\beta\)r,1 后发送 \(\ell\) +Λ, 玩家 i′ 已收到 mr,1 \(\ell\) 当他收到那些 (r, s−1) 消息时。因此玩家 i′ 停止而不传播任何东西;设 Br = Br \(\ell\);并将他自己的 CERT r 设置为 他收到的 0 和 v 的有效 (r, s−1) 消息集。 接下来,我们证明,任何其他验证器 i \(\in\) HSV r,s 要么以 Br = Br 停止 \(\ell\),或 已设置 bi = 0 并传播 (ESIGi(0), ESIGi(H(Br \(\ell\))), \(\sigma\)r,s 我)。确实,因为步骤 s 这是第一次一些验证者应该停止而不传播任何东西,不存在 存在一个步骤 s′ < s 且 s′ −2 ≡1 mod 3 使得 tH (r, s′ −1) 验证者签名为 1。 因此,HSV r,s 中没有验证器以 Br = Br 停止 ǫ。此外,正如步骤 {4, 5, ... 中的所有诚实验证者一样。 。 。 , s−1} 有符号 H(Br \(\ell\)), 确实有 不存在步骤 s′ \(\leq\) s * 且 s′ −2 ≡0 mod 3 使得 tH (r, s′ −1) 验证者已签名 一些 v′′ ̸= H(Br \(\ell\)) —确实,|MSV r,s′−1| < tH。因此,HSV r,s 中没有验证者停止 与 Br ̸= Br ϫ 和 Br ̸= Br \(\ell\)。也就是说,如果一个玩家 i \(\in\) HSV r,s 已经停止而没有 传播任何东西,他一定设置了 Br = Br \(\ell\)。 如果玩家 i \(\in\) HSV r,s 已等待时间 ts 并在时间传播消息 \(\beta\)r,s 我 = \(\alpha\)r,s 我 + ts,他已经收到了来自 HSV r,s−1 的所有消息,至少包括 tH -|MSV r,s−1|其中 0 和 v。 如果我看到 1 的票数超过 2/3,那么他 已经看到超过 2(tH −|MSV r,s−1|) 条有效 (r, s−1)-消息 1,还有更多 比 2tH -3|MSV r,s−1|其中来自诚实的 (r, s−1) 验证者。然而,这意味着 |HSV r,s−1| \(\geq\)tH−|MSV r,s−1|+2tH−3|MSV r,s−1| > 2n−4|MSV r,s−1|,矛盾 事实是 |HSV r,s−1| + 4|MSV r,s−1| < 2n, 它来自参数的关系。因此,我没有看到> 2/3 大多数人支持 1,并且他设置 bi = 0,因为步骤 s 是一个 Coin-Fixed-To-0 步骤。正如我们所拥有的 可见,vi = H(Br \(\ell\))。因此 i 传播 (ESIGi(0), ESIGi(H(Br \(\ell\))), \(\sigma\)r,s i ) 如我们所愿 显示。 对于步骤 s+ 1,由于玩家 i′ 已帮助在其 CERT r 中传播消息 在时间 \(\alpha\)r,s 或之前 我′ + ts,HSV r,s+1 中的所有诚实验证者至少收到 tH 位 0 和值 H(Br \(\ell\)) 完成后或之前 等待。此外,HSV r,s+1 中的验证器在收到这些 (r,s−1)- 之前不会停止 消息,因为对于位 1 不存在任何其他有效的 (r, s′ -1) 消息 s′ −2 ≡1 mod 3 且 6 \(\leq\)s′ \(\leq\)s+ 1,根据步骤 s 的定义。特别是,步骤 s+ 1 本身是一个 Coin-Fixed-To-1 步骤,但 HSV r,s 中没有诚实的验证者传播 1 的消息,以及 |MSV r,s| < tH。 因此,HSV r,s+1 中的所有诚实验证者都会停止而不传播任何内容,并设置 Br = 溴 \(\ell\):和以前一样,他们收到了 mr,1 \(\ell\) 在他们收到所需的 (r, s−1)-消息之前。20 对于未来步骤中的所有诚实验证者和一般的所有诚实用户来说,也可以这样说。 特别是,他们都知道 Br = Br \(\ell\)在时间间隔 Ir+1 内并且 T r+1 \(\leq\) \(\alpha\)r,s 我′ + ts\(\leq\)T r + \(\lambda\) + ts。 案例2.1.b。事件 E.b 发生并且存在一个诚实的验证者 i′ \(\in\)HSV r,s 谁应该 也停止不传播任何东西。 在这种情况下,我们有 s−2 ≡1 mod 3 并且步骤 s 是一个 Coin-Fixed-To-1 步骤。分析 与案例2.1.a类似,省略了很多细节。 20如果\(\ell\)是恶意的,他可能会派出mr,1 \(\ell\) 迟到了,希望一些诚实的用户/验证者还没有收到 mr,1 \(\ell\) 还 当他们收到所需的证书时。然而,由于验证者 ˆi \(\in\)HSV r,4 已设置 bˆi = 0 且 vˆi = H(Br \(\ell\)), 如 在我们有超过一半的诚实验证者 i \(\in\)HSV r,3 已经设置 vi = H(Br \(\ell\))。这进一步意味着更多 超过一半的诚实验证者 i \(\in\)HSV r,2 设置 vi = H(Br \(\ell\)),那些 (r, 2)-验证者都收到了 mr,1 \(\ell\)。作为 对手无法区分验证者和非验证者,他无法瞄准 mr,1 的传播 \(\ell\) 至 (r, 2)-验证者 而不让非验证者看到它。事实上,很有可能超过一半(或一个很好的常数分数) 所有诚实用户都见过 mr,1 \(\ell\) 等待t2后从自己的回合r开始。从现在开始, mr,1 所需时间 \(\lambda\)′ \(\ell\) 到达剩余的诚实用户比 Λ 小得多,为了简单起见,我们不 在分析中写出来。如果 4\(\lambda\) \(\geq\) \(\lambda\)′ 则分析继续进行,没有任何变化:在步骤 4 结束时,所有 诚实的用户会收到 mr,1 \(\ell\)。如果块的大小变得巨大且 4\(\lambda\) < \(\lambda\)′,则在步骤 3 和 4 中, 协议可以要求每个验证者等待 \(\lambda\)′/2 而不是 2\(\lambda\),并且分析继续成立。和之前一样,玩家 i′ 必须至少收到 tH 条有效的 (r, s−1) 消息,其形式为 (ESIGj(1), ESIGj(vj), \(\sigma\)r,s−1 j )。再次根据 s 的定义,不存在步骤 5 \(\leq\)s′ < s,其中 s′ −2 ≡0 mod 3,其中至少 tH (r, s′ −1) 验证者已签署 0 且 相同的 v。因此玩家 i′ 停止而不传播任何东西;设 Br = Br ǫ;和集 他自己的 CERT r 是他收到的第 1 位的有效 (r, s−1) 消息集。 此外,任何其他验证器 i \(\in\) HSV r,s 要么以 Br = Br 停止 \(\varepsilon\) ,或已设定 bi = 1 并传播 (ESIGi(1), ESIGi(vi), \(\sigma\)r,s 我 )。由于玩家 i′ 帮助传播了 在时间 \(\alpha\)r,s 之前,他的 CERT r 中的 (r, s−1) 消息 我′ + ts,再次是所有诚实的验证者 HSV r,s+1 停止而不传播任何东西并设置 Br = Br ǫ .同样,所有诚实的人 用户知道 Br = Br ϫ 在时间间隔 Ir+1 内并且 T r+1 \(\leq\) \(\alpha\)r,s 我′ + ts\(\leq\)T r + \(\lambda\) + ts。 案例 2.2.a.事件 E.a 发生并且不存在诚实的验证者 i′ \(\in\)HSV r,swho 也应该停止而不传播任何东西。 在这种情况下,请注意玩家 i 可能拥有有效的 CERT r i由所需的 tH 组成 (r, s−1) - 对手能够收集或生成的消息。然而,恶意 验证者可能无助于传播这些消息,因此我们不能得出结论说诚实的人 用户将在 \(\lambda\) 时间内收到它们。事实上,|MSV r,s−1|这些消息可能来自 恶意(r,s−1)验证者,他们根本不传播他们的消息,只发送 在步骤 s 中将它们发送给恶意验证者。 与情况 2.1.a 类似,这里我们有 s−2 ≡0 mod 3,步骤 s 是一个 Coin-Fixed-To-0 步骤, 以及 CERT r 中的 (r, s−1) 消息 i 代表位 0 且 v = H(Br \(\ell\))。确实,大家都诚实 (r, s−1)-验证者对 v 进行签名,因此对手无法生成 tH 条有效的 (r, s−1)-消息 对于不同的 v′。 此外,所有诚实的 (r, s) 验证者都等待了 ts 时间,并且没有看到 > 2/3 的多数 对于位 1,同样是因为 |HSV r,s−1| + 4|MSV r,s−1| < 2n。因此,每一个诚实的验证者 i \(\in\)HSV r,s设 bi = 0, vi = H(Br \(\ell\)) 以多数票通过,并传播 mr,s 我 = (ESIGi(0)、ESIGi(H(Br \(\ell\))), \(\sigma\)r,s 我 ) 在时间 \(\alpha\)r,s 我 + ts。 现在考虑步骤 s+ 1 中的诚实验证者(这是一个 Coin-Fixed-To-1 步骤)。如果 攻击者实际上在 CERT r 中发送消息 i对其中一些并导致他们 停止,然后类似于情况2.1.a,所有诚实的用户都知道Br = Br \(\ell\)在时间间隔内 Ir+1 和 T r+1 \(\leq\)T r + \(\lambda\) + ts+1。 否则,步骤 s+1 中的所有诚实验证者都已收到 0 和 的所有 (r, s) 消息 H(溴 \(\ell\)) 来自 HSV r,s 在等待时间 ts+1 后,这导致 > 2/3 多数,因为 |HSV r,s| > 2|MSV r,s|。因此,HSV r,s+1 中的所有验证者将其消息传播为 0 和 H(Br \(\ell\))相应地。请注意,HSV r,s+1 中的验证器不会以 Br = Br 停止 \(\ell\), 因为步骤 s+ 1 不是一个 Coin-Fixed-To-0 步骤。 现在考虑步骤 s+2 中的诚实验证者(这是一个真正翻转硬币的步骤)。 如果攻击者在 CERT r 中发送消息 i对其中一些人并导致他们停止, 那么所有诚实的用户都知道 Br = Br \(\ell\)在时间间隔 Ir+1 内并且 T r+1 \(\leq\)T r + \(\lambda\) + ts+2。否则,步骤 s+ 2 中的所有诚实验证者都已收到所有 (r, s+ 1) 消息 0 和 H(Br \(\ell\)) 在等待时间 ts+2 后从 HSV r,s+1 中生成,这导致 > 2/3 多数。 因此,它们都传播 0 和 H(Br \(\ell\)) 相应地:他们就是这么做的 在这种情况下,不是“抛硬币”。再次注意,它们不会停止传播, 因为步骤 s+ 2 不是一个 Coin-Fixed-To-0 步骤。 最后,对于步骤 s+3 中的诚实验证者(这是另一个 Coin-Fixed-To-0 步骤),所有 他们中的至少 tH 人会收到 0 和 H(Br \(\ell\)) 来自 HSV s+2, 如果他们真的等待时间ts+3。因此,无论对手是否发送消息 在 CERT 中 i对于其中任何一个,HSV r,s+3 中的所有验证器都以 Br = Br 停止 \(\ell\),无 传播任何东西。根据对手的行为方式,其中一些人可能会 他们自己的 CERT r 由 CERT r 中的 (r, s−1) 消息组成 i,其他有 他们自己的 CERT r 由那些 (r, s+ 2) 消息组成。无论如何,所有诚实的用户 知道 Br = Br \(\ell\)在时间间隔 Ir+1 内并且 T r+1 \(\leq\)T r + \(\lambda\) + ts+3。 案例 2.2.b。事件 E.b 发生并且不存在诚实验证者 i′ \(\in\)HSV r,swho 也应该停止而不传播任何东西。 本案例的分析与案例2.1.b和案例2.2.a类似,因此有很多细节 已被省略。特别是,CERT i 由 tH 个所需的 (r, s−1) 消息组成 对于对手能够收集或生成的位 1,s−2 ≡1 mod 3,步骤 s 是 a Coin-Fixed-To-1 步骤,并且任何诚实的 (r, s) 验证者都无法看到 0 的多数票超过 2/3。 因此,每个验证者 i \(\in\) HSV r,s 设置 bi = 1 并传播 mr,s 我 = (ESIGi(1), ESIGi(vi), \(\sigma\)r,s 我 ) 在时间 \(\alpha\)r,s 我 + ts。与案例 2.2.a 类似,最多多 3 个步骤(即协议 到达步骤 s+3,这是另一个 Coin-Fixed-To-1 步骤),所有诚实的用户都知道 Br = Br に 在时间间隔Ir+1内。而且,T r+1 可以\(\leq\)T r+\(\lambda\)+ts+1,或者\(\leq\)T r+\(\lambda\)+ts+2, 或 \(\leq\)T r + \(\lambda\) + ts+3,取决于诚实验证者第一次能够停止的时间 无需传播。 结合四个子情况,我们可以得到在时间间隔内所有诚实用户都知道 Br Ir+1,与 在情况 2.1.a 和 2.1.b 中,T r+1 \(\leq\)T r + \(\lambda\) + ts,并且 在情况 2.2.a 和 2.2.b 中,T r+1 \(\leq\)T r + \(\lambda\) + ts+3。 对于情况 2,它仍然是上限 s,因此 T r+1,我们通过考虑如何做到这一点 很多时候,Coin-Genuinely-Flipped 步骤实际上是在协议中执行的:也就是说, 一些诚实的验证者实际上已经掷硬币了。 特别是,任意固定一个硬币真实翻转步骤 s′(即 7 \(\leq\) s′ \(\leq\) m + 2 且 s′ −2 ≡2 mod 3),令 \(\ell\)′ \(\triangleq\)arg minj\(\in\)SV r,s′−1 H(\(\sigma\)r,s′−1 j )。现在让我们假设 s′ < s, 因为否则的话,根据之前的说法,没有诚实的验证者会在步骤 s' 中实际掷硬币 讨论。 根据 SV r,s′−1 的定义,\(\ell\)′ 凭证的 hash 值也是其中最小的 PKr−k 中的所有用户。由于 hash 函数是随机的 oracle,理想情况下玩家 \(\ell\)′ 是诚实的 概率至少为 h。正如我们稍后将展示的,即使对手尽力预测 随机 oracle 的输出并倾斜概率,玩家 \(\ell\)′ 仍然对概率诚实至少 ph = h2(1 + h −h2)。下面我们考虑确实发生这种情况的情况:也就是说, \(\ell\)′ \(\varepsilon\) HSV r,s′−1。 请注意,每个诚实的验证者 i \(\in\) HSV r,s′ 已收到来自 HSV r,s′−1 的所有消息 时间\(\alpha\)r,s′ 我 + ts′。 如果玩家 i 需要掷硬币(即,他没有看到超过 2/3 的多数票) 相同的位 b \(\in\){0, 1}),那么他设置 bi = lsb(H(\(\sigma\)r,s′−1 \(\ell\)′ ))。如果存在另一个诚实的人 验证者 i′ \(\in\)HSV r,s′ 已经看到 b \(\in\){0, 1} 位的超过 2/3 多数,然后通过属性 引理 5.5 的 (d),HSV r,s' 中没有诚实的验证者会暂时看到 > 2/3 多数 b′ ̸= b。由于 lsb(H(\(\sigma\)r,s′−1 \(\ell\)′ )) = b 以 1/2 的概率,HSV r,s′ 中所有诚实的验证者都达到 以 1/2 的概率就 b 达成一致。当然,如果这样的验证器 i′ 不存在,那么所有 HSV r,s′ 中的诚实验证者同意 lsb(H(\(\sigma\)r,s′−1 \(\ell\)′ )) 概率为 1。 结合 \(\ell\)′ \(\in\)HSV r,s′−1 的概率,我们得到 HSV r,s′ 中的诚实验证者 就比特 b \(\in\){0, 1} 达成一致,概率至少为 ph 2 = h2(1+h−h2) 2 。而且, 通过像以前一样的多数投票归纳,HSV r,s' 中所有诚实的验证者都有他们的 vi 集 为 H(Br \(\ell\))。因此,一旦在步骤 s' 中就 b 达成一致,则 T r+1 为 \(\leq\)T r + \(\lambda\) + ts′+1 或 \(\leq\)T r + \(\lambda\) + ts′+2, 取决于 b = 0 还是 b = 1,根据案例 2.1.a 和 2.1.b 进行分析。在 特别是,不会执行进一步的 Coin-Genuinely-Flipped 步骤:也就是说,验证者 这些步骤仍然会检查它们是否是验证者并因此等待,但它们都会停止而不需要 传播任何东西。因此,在步骤s之前,执行Coin-GenuinelyFlipped步骤的次数根据随机变量Lr进行分配。令步骤 s′ 是根据 Lr 的最后一个硬币真实翻转步骤,通过协议的构建 我们有 s′ = 4 + 3Lr。 如果对手想要延迟 T r+1 尽可能多,他应该什么时候进行步骤 s 可能吗?我们甚至可以假设对手提前知道 Lr 的实现。如果 s> s′ 那么它就没用了,因为诚实的验证者已经在 步骤s′。可以肯定的是,在这种情况下 s 将是 s′ +1 或 s′ +2,同样取决于 b = 0 是否 或 b = 1。然而,这实际上是情况 2.1.a 和 2.1.b,所得的 T r+1 正是 与那种情况相同。更准确地说, T r+1 \(\leq\)T r + \(\lambda\) + ts\(\leq\)T r + \(\lambda\) + ts′+2。 如果 s< s′ -3 —即 s 在倒数第二个硬币真实翻转步骤之前 — 则通过 案例2.2.a和2.2.b的分析, T r+1 \(\leq\)T r + \(\lambda\) + ts+3 < T r + \(\lambda\) + ts′。 也就是说,对手实际上正在使 Br 的协议更快地达成。 如果 s= s′ −2 或 s′ −1 — 即 Coin-Fixed-To-0 步骤或 Coin-Fixed-To-1 步骤 紧接在步骤 s' 之前——然后通过对四个子案例的分析,诚实验证者 步骤 s' 不再能够抛硬币,因为它们要么停止而没有传播, 或已经看到 > 2/3 大多数相同位 b.因此我们有 T r+1 \(\leq\)T r + \(\lambda\) + ts+3 \(\leq\)T r + \(\lambda\) + ts′+2。总而言之,无论 s 是什么,我们都有 T r+1 \(\leq\)T r + \(\lambda\) + ts′+2 = T r + \(\lambda\) + t3Lr+6 = Tr + \(\lambda\) + (2(3Lr + 6) −3)\(\lambda\) + Λ = T r + (6Lr + 10)\(\lambda\) + Λ, 正如我们想要展示的那样。最坏的情况是当 s*= s′ −1 且情况 2.2.b 发生时。 结合二进制 BA 协议的情况 1 和情况 2,引理 5.3 成立。 ■ 5.9 种子 Qr 的安全性和诚实领导者的概率 引理 5.4 仍有待证明。回想一下,第 r 轮中的验证者取自 PKr−k 并且 根据数量 Qr−1 选择。引入回顾参数k的原因 是为了确保,回到 r −k 轮时,对手能够添加新的恶意用户 对于 PKr−k,他无法预测数量 Qr−1,除非概率可以忽略不计。请注意, hash 函数是一个随机 oracle 函数,Qr−1 是在为 r 轮选择验证器时的输入之一。 因此,无论恶意用户如何添加到 PKr−k,从对手的角度来看,每个 其中一个仍然在第 r 轮的步骤中以所需的概率 p(或 p1 代表步骤 1)。更准确地说,我们有以下引理。 引理 5.6。 k = O(log1/2 F),对于每一轮 r,对手以压倒性的概率获胜 没有在 r −k 轮时向随机 oracle 查询 Qr−1。 证明。我们通过归纳法进行。假设对于每一轮 \(\gamma\) < r,对手没有查询 Q\(\gamma\)−1 到第 \(\gamma\) -k.21 轮的随机 oracle 考虑以下心理游戏 对手在 r −k 轮尝试预测 Qr−1。 在每轮的第 1 步中 \(\gamma\) = r −k, 。 。 。 , r −1, 给定一个特定的 Q\(\gamma\)−1,未查询到随机数 oracle,根据 hash 值 H(SIGi(\(\gamma\), 1, Q\(\gamma\)−1)) 对玩家 i \(\in\)PK\(\gamma\)−k 进行排序 我们越来越多地获得 PK\(\gamma\)−k 上的随机排列。根据定义,领导者 \(\ell\) \(\gamma\) 是 排列中的第一个用户并且对概率 h 是诚实的。此外,当 PK\(\gamma\)−k 较大时 足够了,对于任何整数 x \(\geq\)1,排列中前 x 个用户都是的概率 恶意的,但第 (x + 1)st 是诚实的,是 (1 −h)xh。 如果 \(\ell\) \(\gamma\) 是诚实的,则 Q\(\gamma\) = H(SIG\(\ell\) \(\gamma\)(Q\(\gamma\)−1), \(\gamma\))。由于对手无法伪造签名 从对手的角度来看,Q\(\gamma\) 的 \(\ell\) \(\gamma\) 是随机均匀分布的,并且,除了 以指数小概率,22 在 r −k 轮没有被查询到 H。 由于每个 Q\(\gamma\)+1,Q\(\gamma\)+2,. 。 。 、Qr−1 分别是 H 与 Q\(\gamma\)、Q\(\gamma\)+1、... 的输出。 。 。 , Qr−2 作为输入之一, 它们对对手来说都是随机的,并且对手无法在以下时间查询 Qr−1 到 H 轮 r −k。 因此,对手可以在回合中以良好概率预测 Qr−1 的唯一情况 r−k 是当所有领导者 \(\ell\)r−k, . 。 。 , \(\ell\)r−1 是恶意的。再次考虑一轮 \(\gamma\) \(\in\){r−k 。 。 。 , r−1} 以及由相应的 hash 值引起的 PK\(\gamma\)−k 上的随机排列。如果对于某些 x \(\geq\)2,排列中的前 x −1 个用户都是恶意的,第 x 个是诚实的,那么 对手对 Q\(\gamma\) 有 x 种可能的选择:H(SIGi(Q\(\gamma\)−1, \(\gamma\))) 形式之一,其中 i 是以下之一 21由于 k 是一个小整数,不失一般性,我们可以假设协议的前 k 轮已经运行 在安全的环境下,归纳假设对于这些轮次成立。 22 也就是说,H 的输出长度呈指数增长。请注意,这个概率远小于 F。第一个 x−1 恶意用户,通过让玩家 i 成为第 轮 \(\gamma\) 的实际领导者;或 H(Q\(\gamma\)−1, \(\gamma\)),由 迫使 B\(\gamma\) = B\(\gamma\) ǫ .否则,第 \(\gamma\) 轮的领导者将是排列中的第一个诚实用户 Qr−1 对于对手来说变得不可预测。 对手应该采用 Q\(\gamma\) 的上述 x 个选项中的哪一个?去帮助对手 回答这个问题,在心理游戏中我们实际上让他比实际更强大 是,如下。首先,实际上,对手无法计算诚实用户的 hash 签名,因此无法确定对于每个Q\(\gamma\),一开始的恶意用户数x(Q\(\gamma\)) 由 Q\(\gamma\) 引起的第 \(\gamma\) + 1 轮中的随机排列。在心理游戏中,我们给他 免费计算 x(Q\(\gamma\))。其次,实际上,排列中的前 x 个用户都是 恶意并不一定意味着他们都可以成为领导者,因为 hash 它们的签名值也必须小于 p1。我们忽略了这种精神上的束缚 比赛中,给对手更多的优势。 很容易看出,在心理博弈中,对手的最优选择用 ˆQ\(\gamma\) 表示, 是在随机开始时产生最长的恶意用户序列的一个 第 \(\gamma\) + 1 轮的排列。事实上,给定一个特定的 Q\(\gamma\),该协议不依赖于 Q\(\gamma\)−1 对手只能专注于第 \(\gamma\) + 1 轮中的新排列,其中有 开始时恶意用户数量的分布相同。相应地,在每一轮中 \(\gamma\),上面提到的^Q\(\gamma\)给了他最大数量的Q\(\gamma\)+1的选项,从而最大化 连续领导者都是恶意的概率。 因此,在心理游戏中,对手遵循来自 r −k 轮的马尔可夫链 将 r −1 舍入,状态空间为 {0} \(\cup\){x : x \(\geq\)2}。状态 0 表示以下事实: 当前轮 \(\gamma\) 中随机排列中的第一个用户是诚实的,因此对手失败了 预测 Qr−1 的游戏;每个状态 x \(\geq\)2 都表示该状态中的第一个 x −1 个用户 排列是恶意的,第 x 个是诚实的,因此对手有 x 个 Q\(\gamma\) 选项。的 转移概率 P(x, y) 如下。 • 对于任何y \(\geq\)2,P(0, 0) = 1 且P(0, y) = 0。也就是说,对手一旦第一次失败,游戏就失败了。 排列中的用户变得诚实。 • 对于任何x \(\geq\)2,P(x, 0) = hx。也就是说,以概率 hx,所有 x 随机排列都有 他们的第一个用户是诚实的,因此对手在下一轮游戏中失败。 • 对于任何 x \(\geq\)2 且 y \(\geq\)2,P(x, y) 是 x 随机排列中的概率 由 Q\(\gamma\) 的 x 个选项引发,开始时的最长恶意用户序列 其中一些是 y −1,因此对手在下一轮中对于 Q\(\gamma\)+1 有 y 个选项。也就是说, P(x, y) = y−1 X 我=0 (1−h)ih !x - y−2 X 我=0 (1−h)ih !x = (1 −(1 −h)y)x −(1 −(1 −h)y−1)x。 请注意,状态 0 是过渡矩阵 P 中唯一的吸收状态,其他所有状态 x 具有变为 0 的正概率。我们感兴趣的是确定 k 的上限 马尔可夫链以压倒性的概率收敛到 0 所需的轮数:也就是说,没有 无论链从哪个状态开始,对手都以压倒性的概率输掉比赛 并且无法在 r −k 轮预测 Qr−1。 考虑两轮后的转移矩阵 P (2) \(\triangleq\)P \(\cdot\) P。容易看出 P (2)(0, 0) = 1 对于任何 x \(\geq\)2,P (2)(0, x) = 0。对于任何 x \(\geq\)2 且 y \(\geq\)2,当 P(0, y) = 0 时,我们有 P (2)(x, y) = P(x, 0)P(0, y) + X z\(\geq\)2 P(x, z)P(z, y) = X z\(\geq\)2 P(x,z)P(z,y)。令 ¯h \(\triangleq\)1 −h,我们有 P(x, y) = (1 −́hy)x −(1 −́hy−1)x 和 P (2)(x, y) = X z\(\geq\)2 [(1−́hz)x−(1−́hz−1)x][(1−́hy)z−(1−́hy−1)z]。 下面我们计算 P (2)(x,y) 的极限 P(x,y) 当 h 变为 1 时,即 ¯h 变为 0。请注意,最高 P(x, y) 中 ̅h 的阶为 ̅hy−1,系数为 x。据此, 林 小时→1 P (2)(x,y) P(x,y) = 林 ́h \(\to\) 0 P (2)(x,y) P(x,y) = 林 ́h \(\to\) 0 P (2)(x,y) x́hy−1 + O(́hy) = 林 ́h \(\to\) 0 磷 z\(\geq\)2[xˆhz−1 + O(ˆhz)][zˆhy−1 + O(ˆhy)] x́hy−1 + O(́hy) = 林 ́h \(\to\) 0 2x́hy + O(́hy+1) x́hy−1 + O(́hy) = 林 ́h \(\to\) 0 2x ̄hy x́hy−1 = lim h \(\to\) 0 2h = 0。 当 h 足够接近 1,23 时,我们有 P (2)(x,y) P(x,y) \(\leq\)1 2 对于任意 x \(\geq\)2 且 y \(\geq\)2。通过归纳法,对于任何 k > 2,P (k) \(\triangleq\)P k 使得 • P (k)(0, 0) = 1,对于任何 x \(\geq\)2,P (k)(0, x) = 0,并且 • 对于任意 x \(\geq\)2 且 y \(\geq\)2, P (k)(x, y) = P (k−1)(x, 0)P(0, y) + X z\(\geq\)2 P (k−1)(x, z)P(z, y) = X z\(\geq\)2 P (k−1)(x, z)P(z, y) \(\leq\) X z\(\geq\)2 P(x,z) 2k−2 \(\cdot\) P(z, y) = P(2)(x, y) 2k−2 \(\leq\)P(x,y) 2k−1 。 由于 P(x, y) \(\leq\)1,经过 1−log2 F 轮后,进入任何状态 y \(\geq\)2 的转移概率可以忽略不计, 从任何状态 x \(\geq\) 2 开始。虽然这样的状态 y 有很多,但很容易看出 林 y→+∞ P(x,y) P(x, y + 1) = 林 y→+∞ (1−́hy)x−(1−́hy−1)x (1−́hy+1)x−(1−́hy)x= 林 y→+∞ ́hy−1 -́hy ́hy -́hy+1 = 1 h = 1 1 小时。 因此,转移矩阵 P 的每一行 x 作为几何序列以速率减小 1 1−h > 2 当y足够大时,P(k)也是如此。因此,当 k 足够大但仍然 log1/2 F, P 量级 对于任何 x \(\geq\)2,y\(\geq\)2 P (k)(x, y) < F。也就是说,以压倒性的概率 对手输掉了比赛并且未能在 r −k 轮预测 Qr−1。对于 h \(\in\)(2/3, 1],更多 复分析表明存在一个略大于 1/2 的常数 C,因此满足 取 k = O(logC F)。因此引理 5.6 成立。 ■ 引理 5.4。 (重述)给定 r 之前每轮的属性 1-3,Lr 的 ph = h2(1 + h −h2), 并且领导者 \(\ell\)r 是诚实的,概率至少为 ph。 23例如,根据参数的具体选择,h = 80%。
证明。遵循引理 5.6,对手无法在 r −k 轮预测 Qr−1,除非 概率可以忽略不计。请注意,这并不意味着诚实领导者的概率为 h 每轮。事实上,给定 Qr−1,取决于在开始时有多少恶意用户 PKr−k 的随机排列,对手对于 Qr 和 Qr 可能有多个选项 因此可以增加第 r + 1 轮中恶意领导者的概率——我们再次给他 引理5.6中一些不切实际的优点,以简化分析。 然而,对于每个 Qr−1 ,对手在 r −k 轮时没有向 H 查询,对于 任何 x \(\geq\)1,第一个诚实用户出现在结果中的位置 x 的概率为 (1 −h)x−1h PKr−k 的随机排列。当 x = 1 时,第 r + 1 轮中诚实领导者的概率为 确实是h;而当 x = 2 时,对手有两个 Qr 选项,结果概率为 h2。仅通过考虑这两种情况,我们就可以得到回合中诚实领导者的概率 根据需要,r+1至少为h \(\cdot\) h+(1-h)h \(\cdot\) h2=h2(1+h-h2)。 请注意,上述概率仅考虑第 r -k 轮协议中的随机性 到圆河当考虑第 0 轮到第 r 轮的所有随机性时,Qr−1 为 对于对手来说更不可预测,并且第 r + 1 轮中诚实领导者的概率为 至少 h2(1 + h −h2)。将 r + 1 替换为 r 并将所有内容向后移动一轮,即领导者 \(\ell\)r 根据需要,至少有 h2(1 + h −h2) 的概率是诚实的。 类似地,在每个硬币真实翻转步骤 s 中,该步骤的“领导者”——即验证者 在 SV r,s 中,其凭证具有最小 hash 值,其诚实概率至少为 h2(1 + h−h2)。因此 Lr 的 ph = h2(1 + h −h2) 且引理 5.4 成立。 ■
Algorand ′
\(\text{Algorand}^\prime\)
2 In this section, we construct a version of \(\text{Algorand}^\prime\) working under the following assumption. Honest Majority of Users Assumption: More than 2/3 of the users in each \(PK^r\) are honest. In Section 8, we show how to replace the above assumption with the desired Honest Majority of Money assumption. 6.1 Additional Notations and Parameters for \(\text{Algorand}^\prime\) 2 Notations • \(\mu \in \mathbb{Z}^+\): a pragmatic upper-bound to the number of steps that, with overwhelming probability, will actually taken in one round. (As we shall see, parameter \(\mu\) controls how many ephemeral keys a user prepares in advance for each round.) • \(L_r\): a random variable representing the number of Bernoulli trials needed to see a 1, when each trial is 1 with probability \(\frac{p_h}{2}\). \(L_r\) will be used to upper-bound the time needed to generate block \(B_r\). • \(t_H\): a lower-bound for the number of honest verifiers in a step \(s > 1\) of round \(r\), such that with overwhelming probability (given \(n\) and \(p\)), there are \(> t_H\) honest verifiers in \(SV^{r,s}\). Parameters • Relationships among various parameters. — For each step \(s > 1\) of round \(r\), \(n\) is chosen so that, with overwhelming probability,
\(|HSV^{r,s}| > t_H\) and \(|HSV^{r,s}| + 2|MSV^{r,s}| < 2t_H\). Note that the two inequalities above together imply \(|HSV^{r,s}| > 2|MSV^{r,s}|\): that is, there is a 2/3 honest majority among selected verifiers. The closer to 1 the value of \(h\) is, the smaller \(n\) needs to be. In particular, we use (variants of) Chernoffbounds to ensure the desired conditions hold with overwhelming probability. • Example choices of important parameters. — \(F = 10^{-18}\). — \(n \approx 4{,}000\), \(t_H \approx 0.69n\), \(k = 70\). 6.2 Implementing Ephemeral Keys in \(\text{Algorand}^\prime\) 2 Recall that a verifier \(i \in SV^{r,s}\) digitally signs his message \(m_i^{r,s}\) of step \(s\) in round \(r\), relative to an ephemeral public key \(pk_i^{r,s}\), using an ephemeral secrete key \(sk_i^{r,s}\) that he promptly destroys after using. When the number of possible steps that a round may take is capped by a given integer \(\mu\), we have already seen how to practically handle ephemeral keys. For example, as we have explained in \(\text{Algorand}'_1\) (where \(\mu = m + 3\)), to handle all his possible ephemeral keys, from a round \(r'\) to a round \(r' + 10^6\), \(i\) generates a pair \((PMK, SMK)\), where \(PMK\) public master key of an identity based signature scheme, and \(SMK\) its corresponding secret master key. User \(i\) publicizes \(PMK\) and uses \(SMK\) to generate the secret key of each possible ephemeral public key (and destroys \(SMK\) after having done so). The set of \(i\)'s ephemeral public keys for the relevant rounds is \(S = \{i\} \times \{r', \ldots, r' + 10^6\} \times \{1, \ldots, \mu\}\). (As discussed, as the round \(r' + 10^6\) approaches, \(i\) "refreshes" his pair \((PMK, SMK)\).) In practice, if \(\mu\) is large enough, a round of \(\text{Algorand}'_2\) will not take more than \(\mu\) steps. In principle, however, there is the remote possibility that, for some round \(r\) the number of steps actually taken will exceed \(\mu\). When this happens, \(i\) would be unable to sign his message \(m_i^{r,s}\) for any step \(s > \mu\), because he has prepared in advance only \(\mu\) secret keys for round \(r\). Moreover, he could not prepare and publicize a new stash of ephemeral keys, as discussed before. In fact, to do so, he would need to insert a new public master key \(PMK'\) in a new block. But, should round \(r\) take more and more steps, no new blocks would be generated. However, solutions exist. For instance, \(i\) may use the last ephemeral key of round \(r\), \(pk_i^{r,\mu}\), as follows. He generates another stash of key-pairs for round \(r\) —e.g., by (1) generating another master key pair \((PMK, SMK)\); (2) using this pair to generate another, say, \(10^6\) ephemeral keys, \(sk_i^{r,\mu+1}, \ldots, sk_i^{r,\mu+10^6}\), corresponding to steps \(\mu+1, \ldots, \mu+10^6\) of round \(r\); (3) using \(sk_i^{r,\mu}\) to digitally sign \(PMK\) (and any \((r, \mu)\)-message if \(i \in SV^{r,\mu}\)), relative to \(pk_i^{r,\mu}\); and (4) erasing \(SMK\) and \(sk_i^{r,\mu}\). Should \(i\) become a verifier in a step \(\mu + s\) with \(s \in \{1, \ldots, 10^6\}\), then \(i\) digitally signs his \((r, \mu + s)\)- message \(m_i^{r,\mu+s}\) relative to his new key \(pk_i^{r,\mu+s} = (i, r, \mu + s)\). Of course, to verify this signature of \(i\), others need to be certain that this public key corresponds to \(i\)'s new public master key \(PMK\). Thus, in addition to this signature, \(i\) transmits his digital signature of \(PMK\) relative to \(pk_i^{r,\mu}\). Of course, this approach can be repeated, as many times as necessary, should round \(r\) continue for more and more steps! The last ephemeral secret key is used to authenticate a new master public key, and thus another stash of ephemeral keys for round \(r\). And so on.
6.3 The Actual Protocol \(\text{Algorand}'_2\) Recall again that, in each step \(s\) of a round \(r\), a verifier \(i \in SV^{r,s}\) uses his long-term public-secret key pair to produce his credential, \(\sigma_i^{r,s} \triangleq \text{SIG}_i(r, s, Q^{r-1})\), as well as \(\text{SIG}_i(Q^{r-1})\) in case \(s = 1\). Verifier \(i\) uses his ephemeral key pair, \((pk_i^{r,s}, sk_i^{r,s})\), to sign any other message \(m\) that may be required. For simplicity, we write \(\text{esig}_i(m)\), rather than \(\text{sig}_{pk_i^{r,s}}(m)\), to denote \(i\)'s proper ephemeral signature of \(m\) in this step, and write \(\text{ESIG}_i(m)\) instead of \(\text{SIG}_{pk_i^{r,s}}(m) \triangleq (i, m, \text{esig}_i(m))\). Step 1: Block Proposal Instructions for every user \(i \in PK^{r-k}\): User \(i\) starts his own Step 1 of round \(r\) as soon as he has \(\text{CERT}^{r-1}\), which allows \(i\) to unambiguously compute \(H(B^{r-1})\) and \(Q^{r-1}\). • User \(i\) uses \(Q^{r-1}\) to check whether \(i \in SV^{r,1}\) or not. If \(i \notin SV^{r,1}\), he does nothing for Step 1. • If \(i \in SV^{r,1}\), that is, if \(i\) is a potential leader, then he does the following. (a) If \(i\) has seen \(B^0, \ldots, B^{r-1}\) himself (any \(B^j = B^j_\epsilon\) can be easily derived from its hash value in \(\text{CERT}^j\) and is thus assumed "seen"), then he collects the round-\(r\) payments that have been propagated to him so far and computes a maximal payset \(PAY_i^r\) from them. (b) If \(i\) hasn't seen all \(B^0, \ldots, B^{r-1}\) yet, then he sets \(PAY_i^r = \emptyset\). (c) Next, \(i\) computes his "candidate block" \(B_i^r = (r, PAY_i^r, \text{SIG}_i(Q^{r-1}), H(B^{r-1}))\). (c) Finally, \(i\) computes the message \(m_i^{r,1} = (B_i^r, \text{esig}_i(H(B_i^r)), \sigma_i^{r,1})\), destroys his ephemeral secret key \(sk_i^{r,1}\), and then propagates two messages, \(m_i^{r,1}\) and \((\text{SIG}_i(Q^{r-1}), \sigma_i^{r,1})\), separately but simultaneously.a aWhen \(i\) is the leader, \(\text{SIG}_i(Q^{r-1})\) allows others to compute \(Q^r = H(\text{SIG}_i(Q^{r-1}), r)\).
Selective Propagation To shorten the global execution of Step 1 and the whole round, it is important that the \((r, 1)\)- messages are selectively propagated. That is, for every user \(j\) in the system, • For the first \((r, 1)\)-message that he ever receives and successfully verifies,a whether it contains a block or is just a credential and a signature of \(Q^{r-1}\), player \(j\) propagates it as usual. • For all the other \((r, 1)\)-messages that player \(j\) receives and successfully verifies, he propagates it only if the hash value of the credential it contains is the smallest among the hash values of the credentials contained in all \((r, 1)\)-messages he has received and successfully verified so far. • However, if \(j\) receives two different messages of the form \(m_i^{r,1}\) from the same player \(i\),b he discards the second one no matter what the hash value of \(i\)'s credential is. Note that, under selective propagation it is useful that each potential leader \(i\) propagates his credential \(\sigma_i^{r,1}\) separately from \(m_i^{r,1}\):c those small messages travel faster than blocks, ensure timely propagation of the \(m_i^{r,1}\)'s where the contained credentials have small hash values, while make those with large hash values disappear quickly. aThat is, all the signatures are correct and, if it is of the form \(m_i^{r,1}\), both the block and its hash are valid —although \(j\) does not check whether the included payset is maximal for \(i\) or not. bWhich means \(i\) is malicious. cWe thank Georgios Vlachos for suggesting this.
Step 2: The First Step of the Graded Consensus Protocol GC Instructions for every user \(i \in PK^{r-k}\): User \(i\) starts his own Step 2 of round \(r\) as soon as he has \(\text{CERT}^{r-1}\). • User \(i\) waits a maximum amount of time \(t_2 \triangleq \lambda + \Lambda\). While waiting, \(i\) acts as follows. 1. After waiting for time \(2\lambda\), he finds the user \(\ell\) such that \(H(\sigma_\ell^{r,1}) \leq H(\sigma_j^{r,1})\) for all credentials \(\sigma_j^{r,1}\) that are part of the successfully verified \((r, 1)\)-messages he has received so far.a 2. If he has received a block \(B^{r-1}\), which matches the hash value \(H(B^{r-1})\) contained in \(\text{CERT}^{r-1}\),b and if he has received from \(\ell\) a valid message $m_\ell^{r,1} = (B_\ell^r, \text{esig}\ell(H(B\ell^r)), \sigma_\ell^{r,1})\(,c then \)i\( stops waiting and sets \)v'i \triangleq (H(B\ell^r), \ell)$. 3. Otherwise, when time \(t_2\) runs out, \(i\) sets \(v'_i \triangleq \bot\). 4. When the value of \(v'_i\) has been set, \(i\) computes \(Q^{r-1}\) from \(\text{CERT}^{r-1}\) and checks whether \(i \in SV^{r,2}\) or not. 5. If \(i \in SV^{r,2}\), \(i\) computes the message \(m_i^{r,2} \triangleq (\text{ESIG}_i(v'_i), \sigma_i^{r,2})\),d destroys his ephemeral secret key \(sk_i^{r,2}\), and then propagates \(m_i^{r,2}\). Otherwise, \(i\) stops without propagating anything. aEssentially, user \(i\) privately decides that the leader of round \(r\) is user \(\ell\). bOf course, if \(\text{CERT}^{r-1}\) indicates that \(B^{r-1} = B^{r-1}_\epsilon\), then \(i\) has already "received" \(B^{r-1}\) the moment he has \(\text{CERT}^{r-1}\). cAgain, player \(\ell\)'s signatures and the hashes are all successfully verified, and \(PAY_\ell^r\) in \(B_\ell^r\) is a valid payset for round \(r\) —although \(i\) does not check whether \(PAY_\ell^r\) is maximal for \(\ell\) or not. If \(B_\ell^r\) contains an empty payset, then there is actually no need for \(i\) to see \(B^{r-1}\) before verifying whether \(B_\ell^r\) is valid or not. dThe message \(m_i^{r,2}\) signals that player \(i\) considers the first component of \(v'_i\) to be the hash of the next block, or considers the next block to be empty.
Step 3: The Second Step of GC Instructions for every user \(i \in PK^{r-k}\): User \(i\) starts his own Step 3 of round \(r\) as soon as he has \(\text{CERT}^{r-1}\). • User \(i\) waits a maximum amount of time \(t_3 \triangleq t_2 + 2\lambda = 3\lambda + \Lambda\). While waiting, \(i\) acts as follows. 1. If there exists a value \(v\) such that he has received at least \(t_H\) valid messages \(m_j^{r,2}\) of the form \((\text{ESIG}_j(v), \sigma_j^{r,2})\), without any contradiction,a then he stops waiting and sets \(v' = v\). 2. Otherwise, when time \(t_3\) runs out, he sets \(v' = \bot\). 3. When the value of \(v'\) has been set, \(i\) computes \(Q^{r-1}\) from \(\text{CERT}^{r-1}\) and checks whether \(i \in SV^{r,3}\) or not. 4. If \(i \in SV^{r,3}\), then \(i\) computes the message \(m_i^{r,3} \triangleq (\text{ESIG}_i(v'), \sigma_i^{r,3})\), destroys his ephemeral secret key \(sk_i^{r,3}\), and then propagates \(m_i^{r,3}\). Otherwise, \(i\) stops without propagating anything. aThat is, he has not received two valid messages containing \(\text{ESIG}_j(v)\) and a different \(\text{ESIG}_j(\hat{v})\) respectively, from a player \(j\). Here and from here on, except in the Ending Conditions defined later, whenever an honest player wants messages of a given form, messages contradicting each other are never counted or considered valid.
Step 4: Output of GC and The First Step of \(\text{BBA}^\star\) Instructions for every user \(i \in PK^{r-k}\): User \(i\) starts his own Step 4 of round \(r\) as soon as he finishes his own Step 3. • User \(i\) waits a maximum amount of time \(2\lambda\).a While waiting, \(i\) acts as follows. 1. He computes \(v_i\) and \(g_i\), the output of GC, as follows. (a) If there exists a value \(v' \neq \bot\) such that he has received at least \(t_H\) valid messages \(m_j^{r,3} = (\text{ESIG}_j(v'), \sigma_j^{r,3})\), then he stops waiting and sets \(v_i \triangleq v'\) and \(g_i \triangleq 2\). (b) If he has received at least \(t_H\) valid messages \(m_j^{r,3} = (\text{ESIG}_j(\bot), \sigma_j^{r,3})\), then he stops waiting and sets \(v_i \triangleq \bot\) and \(g_i \triangleq 0\).b (c) Otherwise, when time \(2\lambda\) runs out, if there exists a value \(v' \neq \bot\) such that he has received at least \(\lceil \frac{t_H}{2} \rceil\) valid messages \(m_j^{r,3} = (\text{ESIG}_j(v'), \sigma_j^{r,3})\), then he sets \(v_i \triangleq v'\) and \(g_i \triangleq 1\).c (d) Else, when time \(2\lambda\) runs out, he sets \(v_i \triangleq \bot\) and \(g_i \triangleq 0\). 2. When the values \(v_i\) and \(g_i\) have been set, \(i\) computes \(b_i\), the input of \(\text{BBA}^\star\), as follows: \(b_i \triangleq 0\) if \(g_i = 2\), and \(b_i \triangleq 1\) otherwise. 3. \(i\) computes \(Q^{r-1}\) from \(\text{CERT}^{r-1}\) and checks whether \(i \in SV^{r,4}\) or not. 4. If \(i \in SV^{r,4}\), he computes the message \(m_i^{r,4} \triangleq (\text{ESIG}_i(b_i), \text{ESIG}_i(v_i), \sigma_i^{r,4})\), destroys his ephemeral secret key \(sk_i^{r,4}\), and propagates \(m_i^{r,4}\). Otherwise, \(i\) stops without propagating anything. aThus, the maximum total amount of time since \(i\) starts his Step 1 of round \(r\) could be \(t_4 \triangleq t_3 + 2\lambda = 5\lambda + \Lambda\). bWhether Step (b) is in the protocol or not does not affect its correctness. However, the presence of Step (b) allows Step 4 to end in less than \(2\lambda\) time if sufficiently many Step-3 verifiers have "signed \(\bot\)." cIt can be proved that the \(v'\) in this case, if exists, must be unique.
Step \(s\), \(5 \leq s \leq m + 2\), \(s - 2 \equiv 0 \mod 3\): A Coin-Fixed-To-0 Step of \(\text{BBA}^\star\) Instructions for every user \(i \in PK^{r-k}\): User \(i\) starts his own Step \(s\) of round \(r\) as soon as he finishes his own Step \(s - 1\). • User \(i\) waits a maximum amount of time \(2\lambda\).a While waiting, \(i\) acts as follows. – Ending Condition 0: If at any point there exists a string \(v \neq \bot\) and a step \(s'\) such that (a) \(5 \leq s' \leq s\), \(s' - 2 \equiv 0 \mod 3\) —that is, Step \(s'\) is a Coin-Fixed-To-0 step, (b) \(i\) has received at least \(t_H\) valid messages \(m_j^{r,s'-1} = (\text{ESIG}_j(0), \text{ESIG}_j(v), \sigma_j^{r,s'-1})\),b and (c) \(i\) has received a valid message \((\text{SIG}_j(Q^{r-1}), \sigma_j^{r,1})\) with \(j\) being the second component of \(v\), then, \(i\) stops waiting and ends his own execution of Step \(s\) (and in fact of round \(r\)) right away without propagating anything as a \((r, s)\)-verifier; sets \(H(B^r)\) to be the first component of \(v\); and sets his own \(\text{CERT}^r\) to be the set of messages \(m_j^{r,s'-1}\) of step (b) together with \((\text{SIG}_j(Q^{r-1}), \sigma_j^{r,1})\).c – Ending Condition 1: If at any point there exists a step \(s'\) such that (a') \(6 \leq s' \leq s\), \(s' - 2 \equiv 1 \mod 3\) —that is, Step \(s'\) is a Coin-Fixed-To-1 step, and (b') \(i\) has received at least \(t_H\) valid messages $m_j^{r,s'-1} = (\text{ESIG}j(1), \text{ESIG}_j(v_j), \sigma_j^{r,s'-1})$,d then, \(i\) stops waiting and ends his own execution of Step \(s\) (and in fact of round \(r\)) right away without propagating anything as a \((r, s)\)-verifier; sets \(B^r = B^r_\epsilon\); and sets his own \(\text{CERT}^r\) to be the set of messages \(m_j^{r,s'-1}\) of sub-step (b'). – If at any point he has received at least \(t_H\) valid \(m_j^{r,s-1}\)'s of the form \((\text{ESIG}_j(1), \text{ESIG}_j(v_j), \sigma_j^{r,s-1})\), then he stops waiting and sets \(b_i \triangleq 1\). – If at any point he has received at least \(t_H\) valid \(m_j^{r,s-1}\)'s of the form \((\text{ESIG}_j(0), \text{ESIG}_j(v_j), \sigma_j^{r,s-1})\), but they do not agree on the same \(v\), then he stops waiting and sets \(b_i \triangleq 0\). – Otherwise, when time \(2\lambda\) runs out, \(i\) sets \(b_i \triangleq 0\). – When the value \(b_i\) has been set, \(i\) computes \(Q^{r-1}\) from \(\text{CERT}^{r-1}\) and checks whether \(i \in SV^{r,s}\). – If \(i \in SV^{r,s}\), \(i\) computes the message \(m_i^{r,s} \triangleq (\text{ESIG}_i(b_i), \text{ESIG}_i(v_i), \sigma_i^{r,s})\) with \(v_i\) being the value he has computed in Step 4, destroys his ephemeral secret key \(sk_i^{r,s}\), and then propagates \(m_i^{r,s}\). Otherwise, \(i\) stops without propagating anything. aThus, the maximum total amount of time since \(i\) starts his Step 1 of round \(r\) could be $t_s \triangleq t + 2\lambda = (2s - 3)\lambda + \Lambda$. bSuch a message from player \(j\) is counted even if player \(i\) has also received a message from \(j\) signing for 1. Similar things for Ending Condition 1. As shown in the analysis, this is to ensure that all honest users know \(\text{CERT}^r\) within time \(\lambda\) from each other. cUser \(i\) now knows \(H(B^r)\) and his own round \(r\) finishes. He just needs to wait until the actually block \(B^r\) is propagated to him, which may take some additional time. He still helps propagating messages as a generic user, but does not initiate any propagation as a \((r, s)\)-verifier. In particular, he has helped propagating all messages in his \(\text{CERT}^r\), which is enough for our protocol. Note that he should also set \(b_i \triangleq 0\) for the binary BA protocol, but \(b_i\) is not needed in this case anyway. Similar things for all future instructions. dIn this case, it does not matter what the \(v_j\)'s are. 65
Step \(s\), \(6 \leq s \leq m + 2\), \(s - 2 \equiv 1 \mod 3\): A Coin-Fixed-To-1 Step of \(\text{BBA}^\star\) Instructions for every user \(i \in PK^{r-k}\): User \(i\) starts his own Step \(s\) of round \(r\) as soon as he finishes his own Step \(s - 1\). • User \(i\) waits a maximum amount of time \(2\lambda\). While waiting, \(i\) acts as follows. – Ending Condition 0: The same instructions as in a Coin-Fixed-To-0 step. – Ending Condition 1: The same instructions as in a Coin-Fixed-To-0 step. – If at any point he has received at least \(t_H\) valid \(m_j^{r,s-1}\)'s of the form \((\text{ESIG}_j(0), \text{ESIG}_j(v_j), \sigma_j^{r,s-1})\), then he stops waiting and sets \(b_i \triangleq 0\).a – Otherwise, when time \(2\lambda\) runs out, \(i\) sets \(b_i \triangleq 1\). – When the value \(b_i\) has been set, \(i\) computes \(Q^{r-1}\) from \(\text{CERT}^{r-1}\) and checks whether \(i \in SV^{r,s}\). – If \(i \in SV^{r,s}\), \(i\) computes the message \(m_i^{r,s} \triangleq (\text{ESIG}_i(b_i), \text{ESIG}_i(v_i), \sigma_i^{r,s})\) with \(v_i\) being the value he has computed in Step 4, destroys his ephemeral secret key \(sk_i^{r,s}\), and then propagates \(m_i^{r,s}\). Otherwise, \(i\) stops without propagating anything. aNote that receiving \(t_H\) valid \((r, s - 1)\)-messages signing for 1 would mean Ending Condition 1. Step \(s\), \(7 \leq s \leq m + 2\), \(s - 2 \equiv 2 \mod 3\): A Coin-Genuinely-Flipped Step of \(\text{BBA}^\star\) Instructions for every user \(i \in PK^{r-k}\): User \(i\) starts his own Step \(s\) of round \(r\) as soon as he finishes his own step \(s - 1\). • User \(i\) waits a maximum amount of time \(2\lambda\). While waiting, \(i\) acts as follows. – Ending Condition 0: The same instructions as in a Coin-Fixed-To-0 step. – Ending Condition 1: The same instructions as in a Coin-Fixed-To-0 step. – If at any point he has received at least \(t_H\) valid \(m_j^{r,s-1}\)'s of the form \((\text{ESIG}_j(0), \text{ESIG}_j(v_j), \sigma_j^{r,s-1})\), then he stops waiting and sets \(b_i \triangleq 0\). – If at any point he has received at least \(t_H\) valid \(m_j^{r,s-1}\)'s of the form \((\text{ESIG}_j(1), \text{ESIG}_j(v_j), \sigma_j^{r,s-1})\), then he stops waiting and sets \(b_i \triangleq 1\). – Otherwise, when time \(2\lambda\) runs out, letting \(SV_i^{r,s-1}\) be the set of \((r, s - 1)\)-verifiers from whom he has received a valid message \(m_j^{r,s-1}\), \(i\) sets \(b_i \triangleq \text{lsb}(\min_{j \in SV_i^{r,s-1}} H(\sigma_j^{r,s-1}))\). – When the value \(b_i\) has been set, \(i\) computes \(Q^{r-1}\) from \(\text{CERT}^{r-1}\) and checks whether \(i \in SV^{r,s}\). – If \(i \in SV^{r,s}\), \(i\) computes the message \(m_i^{r,s} \triangleq (\text{ESIG}_i(b_i), \text{ESIG}_i(v_i), \sigma_i^{r,s})\) with \(v_i\) being the value he has computed in Step 4, destroys his ephemeral secret key \(sk_i^{r,s}\), and then propagates \(m_i^{r,s}\). Otherwise, \(i\) stops without propagating anything. Remark. In principle, as considered in subsection 6.2, the protocol may take arbitrarily many steps in some round. Should this happens, as discussed, a user \(i \in SV^{r,s}\) with \(s > \mu\) has exhausted
his stash of pre-generated ephemeral keys and has to authenticate his \((r, s)\)-message \(m_i^{r,s}\) by a "cascade" of ephemeral keys. Thus \(i\)'s message becomes a bit longer and transmitting these longer messages will take a bit more time. Accordingly, after so many steps of a given round, the value of the parameter \(\lambda\) will automatically increase slightly. (But it reverts to the original \(\lambda\) once a new block is produced and a new round starts.) Reconstruction of the Round-\(r\) Block by Non-Verifiers Instructions for every user \(i\) in the system: User \(i\) starts his own round \(r\) as soon as he has \(\text{CERT}^{r-1}\). • \(i\) follows the instructions of each step of the protocol, participates the propagation of all messages, but does not initiate any propagation in a step if he is not a verifier in it. • \(i\) ends his own round \(r\) by entering either Ending Condition 0 or Ending Condition 1 in some step, with the corresponding \(\text{CERT}^r\). • From there on, he starts his round \(r + 1\) while waiting to receive the actual block \(B^r\) (unless he has already received it), whose hash \(H(B^r)\) has been pinned down by \(\text{CERT}^r\). Again, if \(\text{CERT}^r\) indicates that \(B^r = B^r_\epsilon\), the \(i\) knows \(B^r\) the moment he has \(\text{CERT}^r\). 6.4 Analysis of \(\text{Algorand}'_2\) The analysis of \(\text{Algorand}'_2\) is easily derived from that of \(\text{Algorand}'_1\). Essentially, in \(\text{Algorand}'_2\), with overwhelming probability, (a) all honest users agree on the same block \(B^r\); the leader of a new block is honest with probability at least \(p_h = h^2(1 + h - h^2)\).
Algorand ′
2 在本节中,我们构建了在以下假设下工作的 Algorand ' 版本。 诚实的大多数用户假设:每个 PKr 中超过 2/3 的用户是诚实的。 在第 8 节中,我们展示了如何用所需的诚实多数来替换上述假设 金钱假设。 6.1 Algorand ′ 的附加符号和参数 2 符号 \(\mu\) \(\varepsilon\)Z+:步数的实用上限,以压倒性的概率, 实际上将在一轮中进行。 (正如我们将看到的,参数 \(\mu\) 控制有多少个短暂的 用户为每轮提前准备的密钥。) • Lr:随机变量,代表看到 1 所需的伯努利试验次数,当每次试验 试验次数为 1,概率为 ph 2. Lr 将用于确定生成所需时间的上限 块 Br。 • tH:第 r 轮步骤 s > 1 中诚实验证者数量的下界,使得 压倒性概率(给定 n 和 p),SV r,s 中有 > tH 个诚实验证者。 参数 • 各种参数之间的关系。 — 对于第 r 轮的每一步 s > 1,选择 n 使得以压倒性的概率,
|HSV r,s| > tH 和 |HSV r,s| + 2|MSV r,s| <2tH。 请注意,上面的两个不等式一起意味着 |HSV r,s| > 2|MSV r,s|:即有 是选定验证者中 2/3 的诚实多数。 h的值越接近1,n需要越小。特别是,我们使用(变体 of) Chernoffbounds 以确保所需条件以压倒性概率成立。 • 重要参数的选择示例。 — F = 10−18。 — n 约 4000,tH 约 0.69n,k = 70。 6.2 在 Algorand ' 中实现临时密钥 2 回想一下,验证者 i \(\in\)SV r,s 对他的消息 mr,s 进行了数字签名 我 r 轮中步骤 s 的数量,相对于 临时公钥 pkr,s i ,使用临时秘密密钥 skr,s 我 他立即摧毁 使用后。 当一轮可能采取的步数受到给定的限制时 整数 \(\mu\),我们已经了解了如何实际处理临时密钥。例如,当我们 已在 Algorand ' 中解释 1(其中 \(\mu\) = m + 3),处理所有可能的临时密钥,从 一轮 r′ 到一轮 r′ + 106,i 生成一对 (PMK, SMK),其中 PMK 公共主控 基于身份的签名方案的密钥,SMK 其相应的秘密主密钥。用户我 公开 PMK 并使用 SMK 生成每个可能的临时公钥的秘密密钥 (并在这样做后销毁 SMK)。相关的 i 的临时公钥集 轮次为 S = {i} \(\times\) {r′, . 。 。 , r′ + 106} \(\times\) {1, . 。 。 ,μ}。 (正如所讨论的,随着 r' + 106 轮的临近, 我“刷新”了他的配对(PMK、SMK)。) 实际上,如果 \(\mu\) 足够大,则一轮 Algorand ′ 2 不会采取超过 \(\mu\) 步。在 然而,原则上,存在一种极小的可能性,即对于某一轮 r 的步数 实际取值将超过μ。当这种情况发生时,我将无法签署他的信息,先生 我 为了 任何步骤 s > \(\mu\),因为他提前为 r 轮准备了 \(\mu\) 个密钥。而且,他 正如之前所讨论的,无法准备和公开新的临时密钥存储。事实上,要做 因此,他需要在新块中插入新的公共主密钥 PMK'。但是,应该舍入 r 采取越来越多的步骤,不会生成新的块。 然而,解决方案是存在的。例如,我可以使用 r 轮的最后一个临时密钥,pkr,μ 我 , 如下。他为 r 轮生成另一个密钥对存储 — 例如,通过 (1) 生成另一个 主密钥对(PMK、SMK); (2) 使用这对生成另一个,例如 106 个临时密钥, 斯克 r,μ+1 我 , . 。 。 , sk r,μ+106 我 ,对应第r轮的步骤μ+1,...,μ+106; (3) 使用 skr,μ 我 以数字方式 符号 PMK(以及任何 (r, \(\mu\)) 消息,如果 i \(\in\)SV r,\(\mu\)),相对于 pkr,\(\mu\) 我 ; (4) 擦除 SMK 和 skr,μ 我 。 我是否应该成为步骤 \(\mu\) + s 中的验证者,其中 s \(\in\){1, . 。 。 , 106},然后我对他的 (r, \(\mu\) + s)- 进行数字签名 消息 mr,μ+s 我 相对于他的新关键PK r,μ+s 我 = (i, r, \(\mu\) + s)。当然,要验证这个签名 对于 i,其他人需要确定该公钥对应于 i 的新公共主密钥 PMK。 因此,除了这个签名之外,i 还传输他相对于 pkr,μ 的 PMK 数字签名 我 。 当然,如果 r 轮继续,这种方法可以根据需要重复多次 越来越多的步骤!最后一个临时密钥用于验证新的主公钥 密钥,因此也是 r 轮的临时密钥的另一个存储。等等。6.3 实际协议 Algorand ′ 2 再次回想一下,在 r 轮的每一步 s 中,验证者 i \(\in\)SV r,s 使用他的长期公开秘密 生成其凭证的密钥对 \(\sigma\)r,s 我 \(\triangleq\)SIGi(r, s, Qr−1),以及 SIGi Qr−1 如果 s = 1。 验证者 i 使用他的临时密钥对,(pkr,s 我,skr,s i ), 签署任何其他可能的消息 m 需要。为了简单起见,我们写 esigi(m),而不是 sigpkr,s i (m),表示 i 的固有短暂性 这一步中m的签名,并写ESIGi(m)而不是SIGpkr,s i (m) \(\triangleq\)(i, m, esigi(m))。 第 1 步:区块提案 对每个用户 i \(\in\)PKr−k 的说明:用户 i 一旦完成,就开始自己的第 r 轮步骤 1 CERT r−1,它允许 i 明确计算 H(Br−1) 和 Qr−1。 • 用户i 使用Qr−1 来检查i 是否属于SV r,1。如果 i /\(\varepsilon\)SV r,1,他对步骤 1 不执行任何操作。 • 如果i \(\in\)SV r,1,也就是说,如果i 是潜在的领导者,那么他会执行以下操作。 (a) 如果我见过 B0,. 。 。 , Br−1 本身(任何 Bj = Bj ϫ 可以很容易地从它的 hash 值中推导出来 在 CERT j 中,因此被假定为“已看到”),然后他收集 R 轮付款 到目前为止已传播给他并计算最大支付集 PAY r 我来自他们。 (b) 如果我还没有看到所有 B0,. 。 。 , Br−1 还没有,那么他设置 PAY r 我=\(\emptyset\)。 (c) 接下来,我计算他的“候选块”Br 我 = (r, 支付 r i , SIGi(Qr−1), H(Br−1))。 (c) 最后,我计算消息 mr,1 我 = (Br i , esigi(H(Br i )), \(\sigma\)r,1 i ), 毁掉了他短暂的 密钥 skr,1 i ,然后传播两条消息 mr,1 我 和 (SIGi(Qr−1), \(\sigma\)r,1 我), 分别但同时.a a当 i 是领导者时,SIGi(Qr−1) 允许其他人计算 Qr = H(SIGi(Qr−1), r)。
选择性传播 为了缩短步骤 1 和整个回合的全局执行时间,重要的是 (r, 1)- 消息是有选择地传播的。也就是说,对于系统中的每个用户 j, • 对于他收到并成功验证的第一条 (r, 1) 消息,a 是否包含 一个区块 or 只是一个凭证和 Qr−1 的签名,玩家 j 像往常一样传播它。 • 对于玩家 j 收到并成功验证的所有其他 (r, 1) 消息,他传播 仅当它包含的凭证的 hash 值是 hash 值中最小的时候才使用它 他已收到并成功验证的所有 (r, 1) 消息中包含的凭据 远。 • 然而,如果j 收到两个不同的消息,其形式为mr,1 我 来自同一个玩家 i,b he 无论 i 凭证的 hash 值是多少,都会丢弃第二个。 请注意,在选择性传播下,每个潜在领导者 i 传播他的信息是有用的 凭证 \(\sigma\)r,1 我 与 mr,1 分开 i :c 这些小消息的传输速度比块快,确保 及时传播 mr,1 i 所包含的凭据具有较小的 hash 值,而 使 hash 值较大的那些快速消失。 a 也就是说,所有签名都是正确的,如果是 mr,1 的形式 i ,该块及其 hash 均有效 —尽管 j 不检查包含的支付集对于 i 是否是最大的。 b这意味着我是恶意的。 c我们感谢 Georgios Vlachos 的建议。第二步:分级共识协议GC的第一步 对每个用户 i \(\in\)PKr−k 的说明:用户 i 一旦完成,就开始自己的第 r 轮步骤 2 CERT r−1。 • 用户i 等待的最长时间为t2 \(\triangleq\) \(\lambda\) + Λ。在等待期间,我的行为如下。 1. 等待时间 2\(\lambda\) 后,他找到用户 \(\ell\),使得 H(\(\sigma\)r,1 \(\ell\)) \(\leq\)H(\(\sigma\)r,1 j) 对于所有人 凭证 \(\sigma\)r,1 j 这是他收到的已成功验证的 (r, 1) 消息的一部分 到目前为止.a 2.如果 他 有 收到 一个 块 Br−1, 其中 比赛 的 hash 值 H(Br−1) H(Br−1) 包含在 CERT r−1,b 中,并且如果他已从 \(\ell\) 收到有效消息 mr,1 \(\ell\) = (Br \(\ell\), esig\(\ell\)(H(Br \(\ell\))), \(\sigma\)r,1 \(\ell\)),c 然后 i 停止等待并设置 v′ 我 \(\triangleq\)(H(Br \(\ell\)),\(\ell\))。 3. 否则,当时间t2用完时,i设置v′ 我\(\triangleq\) \(\bot\)。 4. 当v′的值 i 已设置,i 根据 CERT r−1 计算 Qr−1 并检查是否 i \(\in\)SV r,2 与否。 5. 如果 i \(\in\)SV r,2,则 i 计算消息 mr,2 我 \(\triangleq\)(ESIGi(v′ i), \(\sigma\)r,2 i ),d 摧毁了他的短暂 密钥 skr,2 i ,然后传播 mr,2 我。 否则,我会停止而不传播 任何东西。 a本质上,用户i私下决定r轮的领导者是用户\(\ell\)。 b当然,如果CERT r−1 表明 Br−1 = Br−1 に ,那么当他收到时,我就已经“收到”了 Br−1 CERT r−1。 c再次,玩家\(\ell\)的签名和hashes都已成功验证,并且PAY r \(\ell\) 溴 \(\ell\) 是有效的支付集 回合 r — 尽管我不检查是否 PAY r \(\ell\) 是否为 \(\ell\) 的最大值。如果溴 \(\ell\)包含一个空的支付集,那么 实际上,在验证 Br 是否存在之前,i 不需要看到 Br−1 \(\ell\) 是否有效。 d消息 mr,2 我 表示玩家 i 考虑 v′ 的第一个分量 i 是下一个块的 hash ,或者 认为下一个块是空的。
步骤3:GC第二步 对每个用户 i \(\in\)PKr−k 的说明:用户 i 一旦完成,就开始自己的第 r 轮步骤 3 CERT r−1。 • 用户i 等待的最长时间为t3 \(\triangleq\)t2 + 2\(\lambda\) = 3\(\lambda\) + Λ。在等待时,我充当 接下来。 1.如果存在一个值v使得他至少收到了tH条有效消息mr,2 j 的 形式 (ESIGj(v), \(\sigma\)r,2 j ), 没有任何矛盾, a 然后他停止等待并设置 v′ = v。 2. 否则,当时间 t3 结束时,他设置 v′ = \(\bot\)。 3. 设置 v′ 的值后,i 根据 CERT r−1 计算 Qr−1 并检查是否 i \(\in\)SV r,3 与否。 4. 如果 i \(\in\)SV r,3,则 i 计算消息 mr,3 我 \(\triangleq\)(ESIGi(v′), \(\sigma\)r,3 i ), 毁掉他的 临时密钥 skr,3 i ,然后传播 mr,3 我。 否则,我就停止了 传播任何东西。 a即他没有收到两条分别包含ESIGj(v)和不同ESIGj(ˆv)的有效消息, 来自玩家 j。从现在开始,除了稍后定义的结束条件外,每当诚实的玩家 想要给定形式的消息,相互矛盾的消息永远不会被计算或被认为是有效的。
步骤4:GC的输出和BBA的第一步⋆ 对每个用户 i \(\in\)PKr−k 的说明:用户 i 一旦他开始他自己的第 r 轮步骤 4 完成他自己的第3步。 • 用户i 等待的最长时间为2\(\lambda\).a 在等待期间,i 的操作如下。 1. 他计算 GC 的输出 vi 和 gi,如下所示。 (a) 如果存在一个值 v′ ̸= \(\bot\) 使得他至少收到了 tH 条有效消息 先生,3 j = (ESIGj(v′), \(\sigma\)r,3 j ),然后他停止等待并设置 vi \(\triangleq\)v′ 和 gi \(\triangleq\)2。 (b) 如果他至少收到了 tH 条有效消息 mr,3 j = (ESIGj(\(\bot\)), \(\sigma\)r,3 j ),然后他停下来 等待并设置 vi \(\triangleq\) \(\bot\) 和 gi \(\triangleq\)0.b (c) 否则,当时间 2\(\lambda\) 耗尽时,如果存在值 v′ ̸= \(\bot\),则有 至少收到 ⌈tH 2 ⌉有效消息 mr,j j = (ESIGj(v′), \(\sigma\)r,3 j ), 然后他设置 vi \(\triangleq\)v′ 和 gi \(\triangleq\)1.c (d) 否则,当时间 2\(\lambda\) 耗尽时,他设置 vi \(\triangleq\) \(\bot\) 和 gi \(\triangleq\)0。 2. 当vi和gi的值设置完毕后,i计算BBA⋆的输入bi,如下: 如果 gi = 2,则 bi \(\triangleq\)0,否则 bi \(\triangleq\)1。 3. i 根据 CERT r−1 计算 Qr−1 并检查 i 是否 \(\in\)SV r,4 。 4. 如果 i \(\in\)SV r,4,他计算消息 mr,4 我 \(\triangleq\)(ESIGi(bi), ESIGi(vi), \(\sigma\)r,4 i ), 毁掉他的 临时密钥 skr,4 i ,并传播 mr,4 我。否则,我会停止而不传播 任何东西。 因此,自 i 开始第 r 轮步骤 1 以来的最大总时间可能是 t4 \(\triangleq\)t3 + 2\(\lambda\) = 5\(\lambda\) + Λ。 b 步骤(b)是否在协议中并不影响其正确性。然而,步骤(b)的存在 如果有足够多的第 3 步验证者“签名\(\bot\)”,则第 4 步可以在不到 2\(\lambda\) 的时间内结束。 c可以证明,这种情况下的v′,如果存在的话,一定是唯一的。步骤 s, 5 \(\leq\)s \(\leq\)m + 2, s −2 ≡0 mod 3:BBA⋆的硬币固定至 0 步骤 对每个用户 i \(\in\)PKr−k 的说明:用户 i 一旦他开始,就开始他自己的第 r 轮步骤 s 完成他自己的步骤 s -1。 • 用户i 等待的最长时间为2\(\lambda\).a 在等待期间,i 的操作如下。 – 结束条件 0:如果在任意点存在字符串 v ̸= \(\bot\) 和步骤 s′,使得 (a) 5 \(\leq\) s′ \(\leq\) s, s′ −2 eq 0 mod 3 — 也就是说,步骤 s′ 是一个 Coin-Fixed-To-0 步骤, (b) i 已收到至少 tH 条有效消息 mr,s′−1 j = (ESIGj(0), ESIGj(v), \(\sigma\)r,s′−1 j ),b 和 (c) i 已收到有效消息 (SIGj(Qr−1), \(\sigma\)r,1 j ) 其中 j 是第二个 v 的分量, 然后,i 停止等待并结束自己对步骤 s 的执行(实际上是 r 轮) 立即作为 (r, s) 验证者传播任何内容;将 H(Br) 设为第一个 v 的分量;并将自己的 CERT r 设置为消息集 mr,s′−1 j 步骤(b)的 与 (SIGj(Qr−1), \(\sigma\)r,1 j).c – 结束条件 1:如果在任意点存在步骤 s′,使得 (a’) 6 \(\leq\)s′ \(\leq\)s, s′ -2 eq 1 mod 3 — 即,步骤 s′ 是 Coin-Fixed-To-1 步骤,并且 (b’) i 已收到至少 tH 条有效消息 mr,s’−1 j = (ESIGj(1), ESIGj(vj), \(\sigma\)r,s′−1 j ),d 然后,i 停止等待并结束自己对步骤 s 的执行(实际上是第 r 轮) 不作为 (r, s) 验证者传播任何内容;设 Br = Br \(\varepsilon\) ;并设定了自己的 CERT r 是消息集 mr,s′−1 j 子步骤(b’)的。 – 如果 在 任何 点 他 有 收到 在 至少 tH 有效 先生,s−1 j 的 的 的 形式 (ESIGj(1), ESIGj(vj), \(\sigma\)r,s−1 j ),然后他停止等待并设置 bi \(\triangleq\)1。 – 如果 在 任何 点 他 有 收到 在 至少 tH 有效 先生,s−1 j 的 的 的 形式 (ESIGj(0), ESIGj(vj), \(\sigma\)r,s−1 j ),但他们在同一个 v 上不一致,然后他停下来 等待并设置 bi \(\triangleq\)0。 – 否则,当时间 2\(\lambda\) 耗尽时,i 设置 bi \(\triangleq\)0。 – 设置值 bi 后,i 根据 CERT r−1 计算 Qr−1 并检查是否 i \(\in\)SV r,s。 – 如果 i \(\in\)SV r,s,i 计算消息 mr,s 我 \(\triangleq\)(ESIGi(bi), ESIGi(vi), \(\sigma\)r,s i ) 与 vi 是 他在步骤 4 中计算出的值会破坏他的临时密钥 skr,s 我,然后 传播先生,s 我。否则,我会停止而不传播任何内容。 因此,自 i 开始第 r 轮第 1 步以来的最大总时间可以是 ts \(\triangleq\)ts−1 + 2\(\lambda\) = (2s -3)\(\lambda\) + Λ。 b 即使玩家 i 也收到了来自 j 的签名为 1 的消息,来自玩家 j 的此类消息也会被计数。 结束条件1类似。如分析所示,这是为了确保所有诚实的用户都知道 CERT r 彼此之间的时间间隔为 \(\lambda\)。 cUser i 现在知道 H(Br) 并且他自己的 r 轮结束。他只需要等到实际的区块 Br 出现 传播给他,这可能需要一些额外的时间。他仍然以普通用户的身份帮助传播消息, 但不会作为 (r, s) 验证者启动任何传播。特别是,他帮助传播了所有信息 他的 CERT r,这对于我们的协议来说已经足够了。注意,他还应该为二进制 BA 协议设置 bi \(\triangleq\)0,但是 无论如何,在这种情况下不需要 bi。类似的事情适用于所有未来的指示。 d在这种情况下,vj 是什么并不重要。 65步骤 s, 6 \(\leq\)s \(\leq\)m + 2, s −2 ≡1 mod 3:BBA⋆的硬币固定到 1 步骤 对每个用户 i \(\in\)PKr−k 的说明:用户 i 一旦他开始,就开始他自己的第 r 轮步骤 s 完成他自己的步骤 s -1。 • 用户i 等待的最长时间为2\(\lambda\)。在等待期间,我的行为如下。 – 结束条件 0:与 Coin-Fixed-To-0 步骤中的指令相同。 – 结束条件 1:与 Coin-Fixed-To-0 步骤中的指令相同。 – 如果 在 任何 点 他 有 收到 在 至少 tH 有效 先生,s−1 j 的 的 的 形式 (ESIGj(0), ESIGj(vj), \(\sigma\)r,s−1 j ),然后他停止等待并设置 bi \(\triangleq\)0.a – 否则,当时间 2\(\lambda\) 耗尽时,i 设置 bi \(\triangleq\)1。 – 设置值 bi 后,i 根据 CERT r−1 计算 Qr−1 并检查是否 i \(\in\)SV r,s。 – 如果 i \(\in\)SV r,s,i 计算消息 mr,s 我 \(\triangleq\)(ESIGi(bi), ESIGi(vi), \(\sigma\)r,s i ) 与 vi 是 他在步骤 4 中计算出的值会破坏他的临时密钥 skr,s 我,然后 传播先生,s 我。否则,我会停止而不传播任何内容。 a注意,接收到签名为 1 的 tH 个有效 (r, s −1) 消息意味着结束条件 1。 步骤 s, 7 \(\leq\)s \(\leq\)m + 2, s −2 ≡2 mod 3:BBA⋆的硬币真实翻转步骤 对每个用户 i \(\in\)PKr−k 的说明:用户 i 一旦他开始,就开始他自己的第 r 轮步骤 s 完成自己的步骤 s −1。 • 用户i 等待的最长时间为2\(\lambda\)。在等待期间,我的行为如下。 – 结束条件 0:与 Coin-Fixed-To-0 步骤中的指令相同。 – 结束条件 1:与 Coin-Fixed-To-0 步骤中的指令相同。 – 如果 在 任何 点 他 有 收到 在 至少 tH 有效 先生,s−1 j 的 的 的 形式 (ESIGj(0), ESIGj(vj), \(\sigma\)r,s−1 j ),然后他停止等待并设置 bi \(\triangleq\)0。 – 如果 在 任何 点 他 有 收到 在 至少 tH 有效 先生,s−1 j 的 的 的 形式 (ESIGj(1), ESIGj(vj), \(\sigma\)r,s−1 j ),然后他停止等待并设置 bi \(\triangleq\)1。 – 否则,当时间 2\(\lambda\) 耗尽时,令 SV r,s−1 我 是 (r, s −1) 验证者的集合 他已收到有效消息 mr,s−1 j , i 设 bi \(\triangleq\)lsb(minj\(\in\)SV r,s−1 我 H(\(\sigma\)r,s−1 j ))。 – 设置值 bi 后,i 根据 CERT r−1 计算 Qr−1 并检查是否 i \(\in\)SV r,s。 – 如果 i \(\in\)SV r,s,i 计算消息 mr,s 我 \(\triangleq\)(ESIGi(bi), ESIGi(vi), \(\sigma\)r,s i ) 与 vi 是 他在步骤 4 中计算出的值会破坏他的临时密钥 skr,s 我,然后 传播先生,s 我。否则,我会停止而不传播任何内容。 评论。 原则上,正如第 6.2 小节所考虑的,协议可以采用任意多个 某轮中的步骤。如果发生这种情况,正如所讨论的,用户 i \(\in\)SV r,s 且 s > \(\mu\) 已耗尽
他储存了预先生成的临时密钥,并且必须验证他的 (r, s) 消息 mr,s 我 由一个 临时密钥的“级联”。因此我的消息变得有点长并且传输的时间更长 消息将需要更多时间。因此,在给定回合的这么多步骤之后, 参数 \(\lambda\) 会自动稍微增加。 (但是一旦新的 \(\lambda\) 它就会恢复到原来的 \(\lambda\) 区块生成并开始新一轮。) 非验证者重建 Round-r 区块 系统中每个用户 i 的说明: 用户 i 一旦完成,就开始自己的回合 r CERT r−1。 • i遵循协议每一步的指示,参与所有的传播 消息,但如果他不是步骤中的验证者,则不会在步骤中发起任何传播。 • i 通过在某些情况下输入结束条件 0 或结束条件 1 来结束自己的回合 r 步骤,使用相应的 CERT r。 • 从那时起,他在等待接收实际区块 Br 的同时开始他的回合 r + 1(除非 他已经收到了),其 hash H(Br) 已被 CERT r 确定。再说一遍,如果 CERT r 表示 Br = Br ϫ,i 在获得 CERT r 后就知道 Br。 6.4 Algorand ' 的分析 2 Algorand ' 的分析 2 很容易从 Algorand ' 导出 1. 本质上,在 Algorand ′ 2、与 压倒性概率,(a) 所有诚实用户都同意同一个区块 Br;新的领导者 块是诚实的,概率至少为 ph = h2(1 + h −h2)。
Handling Offline Honest users
Handling Offline Honest users
As we said, a honest user follows all his prescribed instructions, which include that of being online and running the protocol. This is not a major burden in Algorand, since the computation and bandwidth required from a honest user are quite modest. Yet, let us point out that Algorand can be easily modified so as to work in two models, in which honest users are allowed to be offline in great numbers. Before discussing these two models, let us point out that, if the percentage of honest players were 95%, Algorand could still be run setting all parameters assuming instead that \(h = 80\%\). Accordingly, Algorand would continue to work properly even if at most half of the honest players chose to go offline (indeed, a major case of "absenteeism"). In fact, at any point in time, at least 80% of the players online would be honest. From Continual Participation to Lazy Honesty As we saw, \(\text{Algorand}'_1\) and \(\text{Algorand}'_2\) choose the look-back parameter \(k\). Let us now show that choosing \(k\) properly large enables one to remove the Continual Participation requirement. This requirement ensures a crucial property: namely, that the underlying BA protocol \(\text{BBA}^\star\) has a proper honest majority. Let us now explain how lazy honesty provides an alternative and attractive way to satisfy this property.
Recall that a user \(i\) is lazy-but-honest if (1) he follows all his prescribed instructions, when he is asked to participate to the protocol, and (2) he is asked to participate to the protocol only very rarely —e.g., once a week— with suitable advance notice, and potentially receiving significant rewards when he participates. To allow Algorand to work with such players, it just suffices to "choose the verifiers of the current round among the users already in the system in a much earlier round." Indeed, recall that the verifiers for a round \(r\) are chosen from users in round \(r - k\), and the selections are made based on the quantity \(Q_{r-1}\). Note that a week consists of roughly 10,000 minutes, and assume that a round takes roughly (e.g., on average) 5 minutes, so a week has roughly 2,000 rounds. Assume that, at some point of time, a user \(i\) wishes to plan his time and know whether he is going to be a verifier in the coming week. The protocol now chooses the verifiers for a round \(r\) from users in round \(r - k - 2{,}000\), and the selections are based on \(Q_{r-2{,}001}\). At round \(r\), player \(i\) already knows the values \(Q_{r-2{,}000}, \ldots, Q_{r-1}\), since they are actually part of the blockchain. Then, for each \(M\) between 1 and 2,000, \(i\) is a verifier in a step \(s\) of round \(r + M\) if and only if
\[H\bigl(\text{SIG}_i(r + M,\, s,\, Q_{r+M-2{,}001})\bigr) \leq p\]
Thus, to check whether he is going to be called to act as a verifier in the next 2,000 rounds, \(i\) must compute \(\sigma^{M,s}_i = \text{SIG}_i(r + M,\, s,\, Q_{r+M-2{,}001})\) for \(M = 1\) to \(2{,}000\) and for each step \(s\), and check whether \(H(\sigma^{M,s}_i) \leq p\) for some of them. If computing a digital signature takes a millisecond, then this entire operation will take him about 1 minute of computation. If he is not selected as a verifier in any of these rounds, then he can go off-line with an "honest conscience". Had he continuously participated, he would have essentially taken 0 steps in the next 2,000 rounds anyway! If, instead, he is selected to be a verifier in one of these rounds, then he readies himself (e.g., by obtaining all the information necessary) to act as an honest verifier at the proper round. By so acting, a lazy-but-honest potential verifier \(i\) only misses participating to the propagation of messages. But message propagation is typically robust. Moreover, the payers and the payees of recently propagated payments are expected to be online to watch what happens to their payments, and thus they will participate to message propagation, if they are honest.
处理线下诚实用户
正如我们所说,诚实的用户会遵循所有规定的指示,其中包括在线指示 并运行协议。这在 Algorand 中并不是一个主要负担,因为计算和 诚实用户所需的带宽相当适中。然而,让我们指出 Algorand 可以 可以轻松修改,以便在两种模型中工作,其中允许诚实的用户离线 数量巨大。 在讨论这两个模型之前,让我们指出,如果诚实玩家的百分比 是 95%,Algorand 仍然可以运行,设置所有参数,假设 h = 80%。 因此,即使最多一半的诚实玩家,Algorand也会继续正常工作 选择了离线(确实是“旷工”的一个重大案例)。事实上,在任何时候,至少 80%的在线玩家都是诚实的。 从持续参与到懒惰诚实 正如我们所见,Algorand ′ 1 和 Algorand ′ 2 选择 回顾参数k。现在让我们证明,选择适当大的 k 可以使我们删除 持续参与要求。这个要求确保了一个关键的属性:即 底层 BA 协议 BBA⋆拥有适当的诚实多数。现在让我们解释一下如何偷懒 诚实提供了一种替代且有吸引力的方式来满足这一特性。
回想一下,用户 i 是懒惰但诚实的,如果 (1) 他遵循所有规定的指示,当 他被要求参加该协议,并且 (2) 他被要求仅参加该协议 很少——例如每周一次——并有适当的提前通知,并且可能会收到重大的 当他参与时奖励。 为了允许 Algorand 与此类玩家合作,只需“选择 本轮中的用户已在更早一轮的系统中。”确实,请记住 r 轮的验证者是从 r −k 轮的用户中选出的,并且选择是基于 关于数量 Qr−1。请注意,一周大约包含 10,000 分钟,并假设 一轮大约需要(例如,平均)5 分钟,所以一周大约有 2,000 轮。假设 在某个时间点,用户希望计划他的时间并知道他是否会 下周将进行验证。该协议现在从以下用户中选择第 r 轮的验证者 轮 r −k −2, 000,选择基于 Qr−2,001。在 r 轮,我已经认识的玩家 值 Qr−2,000, . 。 。 ,Qr−1,因为它们实际上是 blockchain 的一部分。然后,对于每个M 在 1 到 2,000 之间,i 是第 r + M 轮步骤 s 中的验证者当且仅当 .H 西吉 r + M, s, Qr+M−2,001 \(\leq\)p。 因此,为了检查他是否会在接下来的 2,000 轮中被要求充当验证者,我必须 计算 \(\sigma\)M,s 我 = SIGi r + M, s, Qr+M−2,001 对于 M = 1 到 2, 000 以及对于每个步骤 s,并检查 是否.H(\(\sigma\)M,s 我 ) \(\leq\)p 对于其中一些。如果计算数字签名需要一毫秒,那么 整个操作将花费他大约 1 分钟的计算时间。如果他没有被选为验证者 在任何一轮中,他都可以带着“诚实的良心”下线。如果他不断地 参加的话,接下来的2000回合他基本上就走0步了!相反,如果 他被选为其中一轮的验证者,然后他做好准备(例如,通过获得所有 必要的信息)在适当的回合中充当诚实的验证者。 通过这样的行为,一个懒惰但诚实的潜在验证者 i 只会错过参与传播的机会 的消息。但消息传播通常是稳健的。此外,付款人和收款人 最近传播的支付预计将在线观察他们的支付发生了什么, 因此,如果他们是诚实的,他们就会参与消息传播。
Protocol Algorand ′ with Honest Majority of Money
Protocol \(\text{Algorand}^\prime\) with Honest Majority of Money
We now, finally, show how to replace the Honest Majority of Users assumption with the much more meaningful Honest Majority of Money assumption. The basic idea is (in a proof-of-stake flavor) "to select a user \(i \in PK^{r-k}\) to belong to \(SV^{r,s}\) with a weight (i.e., decision power) proportional to the amount of money owned by \(i\)."24 By our HMM assumption, we can choose whether that amount should be owned at round \(r - k\) or at (the start of) round \(r\). Assuming that we do not mind continual participation, we opt for the latter choice. (To remove continual participation, we would have opted for the former choice. Better said, for the amount of money owned at round \(r - k - 2{,}000\).) There are many ways to implement this idea. The simplest way would be to have each key hold at most 1 unit of money and then select at random \(n\) users \(i\) from \(PK^{r-k}\) such that \(a_i^{(r)} = 1\). 24We should say \(PK^{r-k-2{,}000}\) so as to replace continual participation. For simplicity, since one may wish to require continual participation anyway, we use \(PK^{r-k}\) as before, so as to carry one less parameter.
The Next Simplest Implementation The next simplest implementation may be to demand that each public key owns a maximum amount of money \(M\), for some fixed \(M\). The value \(M\) is small enough compared with the total amount of money in the system, such that the probability a key belongs to the verifier set of more than one step in —say— \(k\) rounds is negligible. Then, a key \(i \in PK^{r-k}\), owning an amount of money \(a_i^{(r)}\) in round \(r\), is chosen to belong to \(SV^{r,s}\) if
\[H\left(\text{SIG}_i\left(r, s, Q^{r-1}\right)\right) \leq p \cdot \frac{a_i^{(r)}}{M}.\]
And all proceeds as before. A More Complex Implementation The last implementation "forced a rich participant in the system to own many keys". An alternative implementation, described below, generalizes the notion of status and consider each user \(i\) to consist of \(K + 1\) copies \((i, v)\), each of which is independently selected to be a verifier, and will own his own ephemeral key \((pk_{i,v}^{r,s}, sk_{i,v}^{r,s})\) in a step \(s\) of a round \(r\). The value \(K\) depends on the amount of money \(a_i^{(r)}\) owned by \(i\) in round \(r\). Let us now see how such a system works in greater detail. Number of Copies Let \(n\) be the targeted expected cardinality of each verifier set, and let \(a_i^{(r)}\) be the amount of money owned by a user \(i\) at round \(r\). Let \(A^r\) be the total amount of money owned by the users in \(PK^{r-k}\) at round \(r\), that is,
\[A^r = \sum_{i \in PK^{r-k}} a_i^{(r)}.\]
If \(i\) is an user in \(PK^{r-k}\), then \(i\)'s copies are \((i, 1), \ldots, (i, K + 1)\), where
\[K = \left\lfloor \frac{n \cdot a_i^{(r)}}{A^r} \right\rfloor.\]
Example. Let \(n = 1{,}000\), \(A^r = 10^9\), and \(a_i^{(r)} = 3.7\) millions. Then,
\[K = \left\lfloor \frac{10^3 \cdot (3.7 \cdot 10^6)}{10^9} \right\rfloor = \lfloor 3.7 \rfloor = 3.\]
Verifiers and Credentials Let \(i\) be a user in \(PK^{r-k}\) with \(K + 1\) copies. For each \(v = 1, \ldots, K\), copy \((i, v)\) belongs to \(SV^{r,s}\) automatically. That is, \(i\)'s credential is \(\sigma_{i,v}^{r,s} \triangleq \text{SIG}_i((i, v), r, s, Q^{r-1})\), but the corresponding condition becomes \(H(\sigma_{i,v}^{r,s}) \leq 1\), which is always true. For copy \((i, K + 1)\), for each Step \(s\) of round \(r\), \(i\) checks whether
\[H\left(\text{SIG}_i\left((i, K + 1), r, s, Q^{r-1}\right)\right) \leq \frac{a_i^{(r)} \cdot n}{A^r} - K.\]
If so, copy \((i, K + 1)\) belongs to \(SV^{r,s}\). To prove it, \(i\) propagates the credential
\[\sigma_{i,K+1}^{r,1} = \text{SIG}_i\left((i, K + 1), r, s, Q^{r-1}\right).\]
Example. As in the previous example, let \(n = 1\text{K}\), \(a_i^{(r)} = 3.7\text{M}\), \(A^r = 1\text{B}\), and \(i\) has 4 copies: \((i, 1), \ldots, (i, 4)\). Then, the first 3 copies belong to \(SV^{r,s}\) automatically. For the 4th one, conceptually, \(\text{Algorand}^\prime\) independently rolls a biased coin, whose probability of Heads is 0.7. Copy \((i, 4)\) is selected if and only if the coin toss is Heads. (Of course, this biased coin flip is implemented by hashing, signing, and comparing —as we have done all along in this paper— so as to enable \(i\) to prove his result.) Business as Usual Having explained how verifiers are selected and how their credentials are computed at each step of a round \(r\), the execution of a round is similar to that already explained.
诚实多数资金协议 Algorand ′
最后,我们现在展示如何用更多的假设来取代“诚实的大多数用户”假设 有意义的诚实多数资金假设。基本思想是(以 proof-of-stake 风格) “选择一个用户 i \(\in\)PKr−k 属于 SV r,s,其权重(即决策能力)与 我拥有的金钱数额。”24 根据我们的 HMM 假设,我们可以选择是否应该在 r −k 轮拥有该金额 或在 r 轮(开始)时。假设我们不介意持续参与,我们选择 后者的选择。 (为了消除持续参与,我们会选择前一种选择。 更好的说法是,在 r −k −2, 000 轮拥有的资金量。) 有很多方法可以实现这个想法。最简单的方法是按住每个键 最多 1 个货币单位,然后从 PKr−k 中随机选择 n 个用户 i,使得 a(r) 我 = 1。 24我们应该说 PKr−k−2,000 来代替持续参与。为简单起见,因为人们可能希望要求 不管怎样继续参与,我们还是像以前一样使用PKr−k,这样可以少带一个参数。
下一个最简单的实现 下一个最简单的实现可能是要求每个公钥拥有最大数量 货币 M,对于某个固定的 M。与货币总量相比,M 的值足够小 系统中的货币,这样一个密钥属于多个验证者集合的概率 比如说,k 轮中的步骤可以忽略不计。那么,一个密钥 i \(\in\) PKr−k,拥有一定数量的货币 a(r) 我 在第 r 轮中,被选择属于 SV r,s 如果 .H 西吉 r, s, Qr−1 \(\leq\)p \(\cdot\) a(r) 我 中号 。 一切都像以前一样进行。 更复杂的实现 最后的实现“迫使系统中的富有参与者拥有许多密钥”。 下面描述的另一种实现概括了状态的概念并考虑 每个用户 i 由 K + 1 个副本 (i, v) 组成,每个副本被独立选择为验证者, 并将拥有自己的临时密钥(pkr,s i,v,skr,s i,v) 在 r 轮的步骤 s 中。 K 值取决于 关于金额 a(r) 我 由 i 在 r 轮中拥有。 现在让我们更详细地看看这样的系统是如何工作的。 份数 令 n 为每个验证器集的目标预期基数,并令 a(r) 我 是用户 i 在第 r 轮拥有的资金量。令 Ar 为拥有的货币总量 由 r 轮 PKr−k 中的用户,即 氩气= X i\(\in\)P Kr−k 一个(r) 我。 如果 i 是 PKr−k 中的用户,则 i 的副本为 (i, 1),…。 。 。 , (i, K + 1),其中 K = $ n \(\cdot\) a(r) 我 氩气 % 。 例子。设 n = 1, 000,Ar = 109,a(r) 我 = 370 万。然后, K = 103 \(\cdot\) (3.7 \(\cdot\) 106) 109 = ⌊3.7⌋= 3 。 验证者和凭证 令 i 为 PKr−k 中的用户,拥有 K + 1 个副本。 对于每个 v = 1,. 。 。 ,K,copy(i,v)自动属于SV r,s。也就是说,我的凭证是 \(\sigma\)r,s i,v \(\triangleq\)SIGi((i, v), r, s, Qr−1),但对应的条件变为.H(\(\sigma\)r,s i,v) \(\leq\)1,即 永远正确。 对于副本 (i, K + 1),对于第 r 轮的每个步骤 s,i 检查是否 .H 西吉 (i, K + 1), r, s, Qr−1 \(\leq\)a(r) 我 n Ar-K。
如果是,则副本 (i, K + 1) 属于 SV r,s。为了证明这一点,我传播了凭证 \(\sigma\)r,1 i,K+1 = SIGi (i, K + 1), r, s, Qr−1 。 例子。 与前面的示例一样,令 n = 1K, a(r) 我 = 3.7M,Ar = 1B,i 有 4 副本:(i, 1), . 。 。 ,(一世,4)。那么,前 3 个副本自动属于 SV r,s。对于第四个来说, 从概念上讲,Algorand ′ 独立地掷出一枚有偏差的硬币,正面朝上的概率为 0.7。复制 当且仅当抛硬币是正面时才选择 (i, 4)。 (当然,这种有偏见的抛硬币是通过hashing、签名和比较来实现的——正如我们 在这篇论文中我一直在做——以便让我能够证明他的结果。) 一切如常 解释了如何选择验证者及其凭证 在一轮 r 的每个步骤中计算,一轮的执行与已经解释的类似。
Handling Forks
Handling Forks
Having reduced the probability of forks to 10−12 or 10−18, it is practically unnecessary to handle them in the remote chance that they occur. Algorand, however, can also employ various fork resolution procedures, with or without proof of work. One possible way of instructing the users to resolve forks is as follows: • Follow the longest chain if a user sees multiple chains. • If there are more than one longest chains, follow the one with a non-empty block at the end. If all of them have empty blocks at the end, consider their second-last blocks. • If there are more than one longest chains with non-empty blocks at the end, say the chains are of length r, follow the one whose leader of block r has the smallest credential. If there are ties, follow the one whose block r itself has the smallest hash value. If there are still ties, follow the one whose block r is ordered the first lexicographically.
处理分叉
将分叉概率降低到 10−12 或 10−18 后,实际上没有必要处理 它们发生的可能性很小。 然而,Algorand 也可以使用各种分叉 解决程序,有或没有工作证明。 指导用户解决分叉的一种可能方法如下: • 如果用户看到多个链,则遵循最长的链。 • 如果有多个最长的链,则在该链的末尾添加一个非空块。如果 它们的末尾都有空块,考虑它们的倒数第二个块。 • 如果有多个最长的链末尾有非空块,则称这些链是 长度为 r,跟随块 r 的领导者拥有最小凭证的那个。如果有联系, 遵循块 r 本身具有最小 hash 值的块。如果仍然存在联系,请按照 其块 r 按字典顺序排列在第一个。
Handling Network Partitions
Handling Network Partitions
As said, we assume the propagation times of messages among all users in the network are upperbounded by \(\lambda\) and \(\Lambda\). This is not a strong assumption, as today's Internet is fast and robust, and the actual values of these parameters are quite reasonable. Here, let us point out that \(\text{Algorand}^\prime_2\) continues to work even if the Internet occasionally got partitioned into two parts. The case when the Internet is partitioned into more than two parts is similar. 10.1 Physical Partitions First of all, the partition may be caused by physical reasons. For example, a huge earthquake may end up completely breaking down the connection between Europe and America. In this case, the malicious users are also partitioned and there is no communication between the two parts. Thus
there will be two Adversaries, one for part 1 and the other for part 2. Each Adversary still tries to break the protocol in its own part. Assume the partition happens in the middle of round \(r\). Then each user is still selected as a verifier based on \(PK^{r-k}\), with the same probability as before. Let \(HSV^{r,s}_i\) and \(MSV^{r,s}_i\) respectively be the set of honest and malicious verifiers in a step \(s\) in part \(i \in \{1, 2\}\). We have
\[|HSV^{r,s}_1| + |MSV^{r,s}_1| + |HSV^{r,s}_2| + |MSV^{r,s}_2| = |HSV^{r,s}| + |MSV^{r,s}|.\]
Note that \(|HSV^{r,s}| + |MSV^{r,s}| < |HSV^{r,s}| + 2|MSV^{r,s}| < 2t_H\) with overwhelming probability. If some part \(i\) has \(|HSV^{r,s}_i| + |MSV^{r,s}_i| \geq t_H\) with non-negligible probability, e.g., 1%, then the probability that \(|HSV^{r,s}_{3-i}| + |MSV^{r,s}_{3-i}| \geq t_H\) is very low, e.g., \(10^{-16}\) when \(F = 10^{-18}\). In this case, we may as well treat the smaller part as going offline, because there will not be enough verifiers in this part to generate \(t_H\) signatures to certify a block. Let us consider the larger part, say part 1 without loss of generality. Although \(|HSV^{r,s}| < t_H\) with negligible probability in each step \(s\), when the network is partitioned, \(|HSV^{r,s}_1|\) may be less than \(t_H\) with some non-negligible probability. In this case the Adversary may, with some other non-negligible probability, force the binary BA protocol into a fork in round \(r\), with a nonempty block \(B_r\) and the empty block \(B^r_\epsilon\) both having \(t_H\) valid signatures.25 For example, in a Coin-Fixed-To-0 step \(s\), all verifiers in \(HSV^{r,s}_1\) signed for bit 0 and \(H(B_r)\), and propagated their messages. All verifiers in \(MSV^{r,s}_1\) also signed 0 and \(H(B_r)\), but withheld their messages. Because \(|HSV^{r,s}_1| + |MSV^{r,s}_1| \geq t_H\), the system has enough signatures to certify \(B_r\). However, since the malicious verifiers withheld their signatures, the users enter step \(s + 1\), which is a Coin-Fixed-To-1 step. Because \(|HSV^{r,s}_1| < t_H\) due to the partition, the verifiers in \(HSV^{r,s+1}_1\) did not see \(t_H\) signatures for bit 0 and they all signed for bit 1. All verifiers in \(MSV^{r,s+1}_1\) did the same. Because \(|HSV^{r,s+1}_1| + |MSV^{r,s+1}_1| \geq t_H\), the system has enough signatures to certify \(B^r_\epsilon\). The Adversary then creates a fork by releasing the signatures of \(MSV^{r,s}_1\) for 0 and \(H(B_r)\). Accordingly, there will be two \(Q_r\)'s, defined by the corresponding blocks of round \(r\). However, the fork will not continue and only one of the two branches may grow in round \(r + 1\). Additional Instructions for \(\text{Algorand}^\prime_2\). When seeing a non-empty block \(B_r\) and the empty block \(B^r_\epsilon\), follow the non-empty one (and the \(Q_r\) defined by it). Indeed, by instructing the users to go with the non-empty block in the protocol, if a large amount of honest users in \(PK^{r+1-k}\) realize there is a fork at the beginning of round \(r + 1\), then the empty block will not have enough followers and will not grow. Assume the Adversary manages to partition the honest users so that some honest users see \(B_r\) (and perhaps \(B^r_\epsilon\)), and some only see \(B^r_\epsilon\). Because the Adversary cannot tell which one of them will be a verifier following \(B_r\) and which will be a verifier following \(B^r_\epsilon\), the honest users are randomly partitioned and each one of them still becomes a verifier (either with respect to \(B_r\) or with respect to \(B^r_\epsilon\)) in a step \(s > 1\) with probability \(p\). For the malicious users, each one of them may have two chances to become a verifier, one with \(B_r\) and the other with \(B^r_\epsilon\), each with probability \(p\) independently. Let \(HSV^{r+1,s}_{1;B_r}\) be the set of honest verifiers in step \(s\) of round \(r+1\) following \(B_r\). Other notations such as \(HSV^{r+1,s}_{1;B^r_\epsilon}\), \(MSV^{r+1,s}_{1;B_r}\) and \(MSV^{r+1,s}_{1;B^r_\epsilon}\) are similarly defined. By Chernoff bound, it is easy 25Having a fork with two non-empty blocks is not possible with or without partitions, except with negligible probability.
to see that with overwhelming probability,
\[|HSV^{r+1,s}_{1;B_r}| + |HSV^{r+1,s}_{1;B^r_\epsilon}| + |MSV^{r+1,s}_{1;B_r}| + |MSV^{r+1,s}_{1;B^r_\epsilon}| < 2t_H.\]
Accordingly, the two branches cannot both have \(t_H\) proper signatures certifying a block for round \(r + 1\) in the same step \(s\). Moreover, since the selection probabilities for two steps \(s\) and \(s^\prime\) are the same and the selections are independent, also with overwhelming probability
\[|HSV^{r+1,s}_{1;B_r}| + |MSV^{r+1,s}_{1;B_r}| + |HSV^{r+1,s^\prime}_{1;B^r_\epsilon}| + |MSV^{r+1,s^\prime}_{1;B^r_\epsilon}| < 2t_H,\]
for any two steps \(s\) and \(s^\prime\). When \(F = 10^{-18}\), by the union bound, as long as the Adversary cannot partition the honest users for a long time (say \(10^4\) steps, which is more than 55 hours with \(\lambda = 10\) seconds26), with high probability (say \(1 - 10^{-10}\)) at most one branch will have \(t_H\) proper signatures to certify a block in round \(r + 1\). Finally, if the physical partition has created two parts with roughly the same size, then the probability that \(|HSV^{r,s}_i| + |MSV^{r,s}_i| \geq t_H\) is small for each part \(i\). Following a similar analysis, even if the Adversary manages to create a fork with some non-negligible probability in each part for round \(r\), at most one of the four branches may grow in round \(r + 1\). 10.2 Adversarial Partition Second of all, the partition may be caused by the Adversary, so that the messages propagated by the honest users in one part will not reach the honest users in the other part directly, but the Adversary is able to forward messages between the two parts. Still, once a message from one part reaches an honest user in the other part, it will be propagated in the latter as usual. If the Adversary is willing to spend a lot of money, it is conceivable that he may be able to hack the Internet and partition it like this for a while. The analysis is similar to that for the larger part in the physical partition above (the smaller part can be considered as having population 0): the Adversary may be able to create a fork and each honest user only sees one of the branches, but at most one branch may grow. 10.3 Network Partitions in Sum Although network partitions can happen and a fork in one round may occur under partitions, there is no lingering ambiguity: a fork is very short-lived, and in fact lasts for at most a single round. In all parts of the partition except for at most one, the users cannot generate a new block and thus (a) realize there is a partition in the network and (b) never rely on blocks that will "vanish". Acknowledgements We would like to first acknowledge Sergey Gorbunov, coauthor of the cited Democoin system. Most sincere thanks go to Maurice Herlihy, for many enlightening discussions, for pointing out that pipelining will improve Algorand's throughput performance, and for greatly improving the 26Note that a user finishes a step \(s\) without waiting for \(2\lambda\) time only if he has seen at least \(t_H\) signatures for the same message. When there are not enough signatures, each step will last for \(2\lambda\) time.
exposition of an earlier version of this paper. Many thanks to Sergio Rajsbaum, for his comments on an earlier version of this paper. Many thanks to Vinod Vaikuntanathan, for several deep discussions and insights. Many thanks to Yossi Gilad, Rotem Hamo, Georgios Vlachos, and Nickolai Zeldovich for starting to test these ideas, and for many helpful comments and discussions. Silvio Micali would like to personally thank Ron Rivest for innumerable discussions and guidance in cryptographic research over more than 3 decades, for coauthoring the cited micropayment system that has inspired one of the verifier selection mechanisms of Algorand. We hope to bring this technology to the next level. Meanwhile the travel and companionship are great fun, for which we are very grateful.
处理网络分区
如前所述,我们假设网络中所有用户之间的消息传播时间的上限为 \(\lambda\) 和 Λ。这不是一个强有力的假设,因为当今的互联网快速且强大,并且 这些参数的实际值是相当合理的。在此,我们指出 Algorand ′ 2 即使互联网偶尔被分成两部分,它仍然可以继续工作。情况当 互联网被分为两个以上的部分也是类似的。 10.1 物理分区 首先,分区可能是物理原因造成的。例如,一场大地震可能会 最终彻底切断了欧洲和美洲之间的联系。在这种情况下, 恶意用户也被分区,并且两部分之间没有通信。因此
将有两个对手,一个用于第 1 部分,另一个用于第 2 部分。每个对手仍然试图 破坏协议本身的一部分。 假设分区发生在 r 轮的中间。那么每个用户仍然被选为 基于 PKr−k 的验证器,概率与之前相同。设 HSV r,s 我 和 MSV r,s 我 分别 是第 i 部分 \(\in\){1, 2} 中步骤 s 中诚实和恶意验证者的集合。我们有 |HSV r,s 1 | + |MSV r,s 1 | + |HSV r,s 2 | + |MSV r,s 2 | = |HSV r,s| + |MSV r,s|。 请注意 |HSV r,s| + |MSV r,s| < |HSV r,s| + 2|MSV r,s| < 2tH 以压倒性的概率。 如果 i 的某个部分有 |HSV r,s 我 | + |MSV r,s 我 | \(\geq\)tH 以不可忽略的概率,例如 1%,则 |HSV r,s 的概率 3−i| + |MSV r,s 3−i| \(\geq\)tH 非常低,例如,当 F = 10−18 时,为 10−16。在这种情况下, 我们不妨将较小的部分视为离线,因为没有足够的验证者 这部分生成签名来证明一个块。 让我们考虑较大的部分,即不失一般性的第一部分。虽然 |HSV r,s| < tH 在每个步骤 s 中的概率可忽略不计,当网络分区时,|HSV r,s 1 |可能是 小于 tH 的概率不可忽略。 在这种情况下,对手可能会用一些 其他不可忽略的概率,迫使二进制 BA 协议在 r 轮中进入分叉,其中包含非空块 Br 和空块 Br ϫ 都具有 TH 有效签名。25 例如,在 Coin-Fixed-To-0 步骤 s,HSV r,s 中的所有验证器 1 对位 0 和 H(Br) 进行签名,并传播它们 消息。 MSV r,s 中的所有验证者 1 还签署了 0 和 H(Br),但保留了他们的信息。因为 |HSV r,s 1 | + |MSV r,s 1 | \(\geq\)tH,系统有足够的签名来证明Br。然而,自从 恶意验证者隐瞒签名,用户输入步骤 s + 1,这是 Coin-Fixed-To1 步骤。因为 |HSV r,s 1 | < tH 由于分区,HSV 中的验证器 r,s+1 1 没看到tH 位 0 的签名,并且它们都为位 1 签名。 MSV r,s+1 中的所有验证者 1 也做了同样的事。因为 |HSV r,s+1 1 | + |MSV r,s+1 1 | \(\geq\)tH,系统有足够的签名来证明 Br ǫ。对手 然后通过释放 MSV r,s 的签名来创建分叉 1 对于 0 和 H(Br)。 因此,将有两个 Qr,由 r 轮的相应块定义。然而, 分叉不会继续,并且在第 r + 1 轮中只有两个分支之一可以生长。 Algorand 的附加说明 2. 当看到非空块 Br 和空块时 嵌段Br \(\varepsilon\) ,跟随非空的(以及由它定义的 Qr)。 事实上,通过指示用户使用协议中的非空块,如果一个大的块 PKr+1−k 中的诚实用户数量意识到在第 r+1 轮开始时有一个分叉,然后 空块将没有足够的追随者并且不会增长。假设对手设法 对诚实用户进行分区,以便一些诚实用户看到 Br(也许 Br ϫ),有的只看到 溴 ǫ。因为对手无法判断其中哪一个将成为 Br 之后的验证者,哪一个将成为 Br 的验证者 将成为以下 Br 的验证者 \(\varepsilon\) , 诚实用户被随机划分并且每一个仍然 成为验证者(无论是关于 Br 还是关于 Br \(\varepsilon\)) 在步骤 s > 1 的概率 p。对于恶意用户来说,他们每个人可能有两次成为验证者的机会,一次是 Br 和另一个带有 Br 的 \(\varepsilon\),每个都有概率 p 独立。 设 HSV r+1,s 1;溴 是 Br 之后的第 r+1 轮步骤 s 中的诚实验证者集合。其他符号 例如HSV r+1,s 1;Brǫ , MSV r+1,s 1;溴 和 MSV r+1,s 1;Brǫ 也有类似的定义。通过 Chernoffbound,这很容易 25无论有或没有分区,都不可能有一个带有两个非空块的分叉,除非可以忽略不计。 概率。以压倒性的概率看到, |HSV r+1,s 1;Br | + |HSV r+1,s 1;Brǫ | + |MSV r+1,s 1;Br | + |MSV r+1,s 1;Brǫ | <2tH。 因此,两个分支不能同时拥有证明一个区块的正确签名。 r + 1 在同一步骤 s 中。此外,由于两个步骤 s 和 s' 的选择概率是 相同并且选择是独立的,也具有压倒性的概率 |HSV r+1,s 1;Br | + |MSV r+1,s 1;Br | + |HSV r+1,s′ 1;Brǫ | + |MSV r+1,s′ 1;Brǫ | <2tH, 对于任意两个步骤 s 和 s'。当 F = 10−18 时,根据并集界限,只要对手不能 对诚实用户进行长时间分区(例如 104 步,超过 55 小时,且 \(\lambda\) = 10 秒26),最多有一个分支具有高概率(例如 1−10−10)具有 tH 个正确的签名 验证第 r + 1 轮中的区块。 最后,如果物理分区创建了两个大小大致相同的部分,则 |HSV r,s 的概率 我 | + |MSV r,s 我 | \(\geq\)tH 对于每个部分 i 都很小。经过类似的分析, 即使对手设法以每个部分都有不可忽略的概率创建一个分叉 对于第 r 轮,在第 r + 1 轮中最多可以生长四个分支之一。 10.2 对抗性划分 其次,分区可能是由Adversary造成的,从而导致消息传播 一部分的诚实用户不会直接到达另一部分的诚实用户,但是 对手能够在两个部分之间转发消息。尽管如此,一旦有人发来一条消息 一部分到达另一部分的诚实用户,它将像往常一样在后者中传播。如果 对手愿意花很多钱,可以想象他可能能够破解 像这样上网并分区一段时间。 分析与上面物理分区中较大部分的分析类似(较小的部分) 部分可以被视为人口为 0):对手也许能够创建一个分叉并 每个诚实的用户只能看到其中一个分支,但最多只能生长一个分支。 10.3 网络分区总和 虽然网络分区可能会发生,并且分区下可能会发生一轮分叉,但是 没有任何挥之不去的歧义:分叉的寿命非常短暂,实际上最多只能持续一轮。在 分区的所有部分除了最多一个之外,用户无法生成新块,因此 (a) 认识到网络中存在分区,并且 (b) 永远不要依赖会“消失”的区块。 致谢 我们首先要感谢谢尔盖 \(\cdot\) 戈尔布诺夫 (Sergey Gorbunov),他是所引用的 Democoin 系统的合著者。 最诚挚的感谢莫里斯 \(\cdot\) 赫利希 (Maurice Herlihy),他进行了许多富有启发性的讨论,指出了 指出流水线将提高 Algorand 的吞吐量性能,并大大提高 26请注意,只有当用户至少看到了 tH 个签名时,他才无需等待 2\(\lambda\) 时间即可完成步骤 s。 同一条消息。当没有足够的签名时,每一步将持续2\(\lambda\)时间。
对本文早期版本的阐述。非常感谢 Sergio Rajsbaum 的评论 本文的早期版本。非常感谢 Vinod Vaikuntanathan 的多次深入讨论 和见解。非常感谢 Yossi Gilad、Rotem Hamo、Georgios Vlachos 和 Nickolai Zeldovich 感谢您开始测试这些想法,并获得许多有用的评论和讨论。 Silvio Micali 谨亲自感谢 Ron Rivest 的无数讨论和指导 从事密码学研究超过 30 年,共同创作了所引用的小额支付系统 这启发了 Algorand 的验证者选择机制之一。 我们希望将这项技术提升到一个新的水平。同时,旅行和陪伴 非常有趣,我们对此非常感激。