You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

117 lines
6.8 KiB

  1. \section{Definitions} \label{sec:definitions}
  2. \subsection{Model}
  3. We consider a system of processes that communicate by exchanging messages.
  4. Processes can be correct or faulty, where a faulty process can behave in an
  5. arbitrary way, i.e., Byzantine faults. We assume that each process
  6. has some amount of voting power (voting power of a process can be $0$).
  7. Processes in our model are not part of a single administrative domain;
  8. therefore we cannot enforce a direct network connectivity between all
  9. processes. Instead, we assume that each process is connected to a subset of
  10. processes called peers, such that there is an indirect communication channel
  11. between all correct processes. Communication between processes is established
  12. using a gossip protocol \cite{Dem1987:gossip}.
  13. Formally, we model the network communication using the \emph{partially
  14. synchronous system model}~\cite{DLS88:jacm}: in all executions of the system
  15. there is a bound $\Delta$ and an instant GST (Global Stabilization Time) such
  16. that all communication among correct processes after GST is reliable and
  17. $\Delta$-timely, i.e., if a correct process $p$ sends message $m$ at time $t
  18. \ge GST$ to correct process $q$, then $q$ will receive $m$ before $t +
  19. \Delta$\footnote{Note that as we do not assume direct communication channels
  20. among all correct processes, this implies that before the message $m$
  21. reaches $q$, it might pass through a number of correct processes that will
  22. forward the message $m$ using gossip protocol towards $q$.}. Messages among
  23. correct processes can be delayed, dropped or duplicated before GST.
  24. Spoofing/impersonation attacks are assumed to be impossible at all times due to
  25. the use of public-key cryptography. The bound $\Delta$ and GST are system
  26. parameters whose values are not required to be known for the safety of our
  27. algorithm. Termination of the algorithm is guaranteed within a bounded duration
  28. after GST. In practice, the algorithm will work correctly in the slightly
  29. weaker variant of the model where the system alternates between (long enough)
  30. good periods (corresponds to the \emph{after} GST period where system is
  31. reliable and $\Delta$-timely) and bad periods (corresponds to the period
  32. \emph{before} GST during which the system is asynchronous and messages can be
  33. lost), but consideration of the GST model simplifies the discussion.
  34. We assume that process steps (which might include sending and receiving
  35. messages) take zero time. Processes are equipped with clocks so they can
  36. measure local timeouts. All protocol messages are signed, i.e., when a correct
  37. process $q$ receives a signed message $m$ from its peer, the process $q$ can
  38. verify who was the original sender of the message $m$.
  39. The details of the Tendermint gossip protocol will be discussed in a separate
  40. technical report. For the sake of this paper it is sufficient to assume that
  41. messages are being gossiped between processes and the following property holds
  42. (in addition to the partial synchrony network assumptions):
  43. \begin{itemize} \item \emph{Gossip communication:} If a correct process $p$
  44. receives some message $m$ at time $t$, all correct processes will receive
  45. $m$ before $max\{t, GST\} + \Delta$. \end{itemize}
  46. %Messages that are being gossiped are created by the consensus layer. We can
  47. %think about consensus protocol as a content creator, which %defines what
  48. %messages should be disseminated using the gossip protocol. A correct
  49. %process creates the message for dissemination either i) %explicitly, by
  50. %invoking \emph{send} function as part of the consensus protocol or ii)
  51. %implicitly, by receiving a message from some other %process. Note that in
  52. %the case ii) gossiping of messages is implicit, i.e., it happens without
  53. %explicit send clause in the consensus algorithm %whenever a correct
  54. %process receives some messages in the consensus algorithm\footnote{If a
  55. %message is received by a correct process at %the consensus level then it
  56. %is considered valid from the protocol point of view, i.e., it has a
  57. %correct signature, a proper message structure %and a valid height and
  58. %round number.}.
  59. %\item Processes keep resending messages (in case of failures or message loss)
  60. %until all its peers get them. This ensures that every message %sent or
  61. %received by a correct process is eventually received by all correct
  62. %processes.
  63. \subsection{State Machine Replication}
  64. State machine replication (SMR) is a general approach for replicating services
  65. modeled as a deterministic state machine~\cite{Lam78:cacm,Sch90:survey}. The
  66. key idea of this approach is to guarantee that all replicas start in the same
  67. state and then apply requests from clients in the same order, thereby
  68. guaranteeing that the replicas' states will not diverge. Following
  69. Schneider~\cite{Sch90:survey}, we note that the following is key for
  70. implementing a replicated state machine tolerant to (Byzantine) faults:
  71. \begin{itemize} \item \emph{Replica Coordination.} All [non-faulty] replicas
  72. receive and process the same sequence of requests. \end{itemize}
  73. Moreover, as Schneider also notes, this property can be decomposed into two
  74. parts, \emph{Agreement} and \emph{Order}: Agreement requires all (non-faulty)
  75. replicas to receive all requests, and Order requires that the order of received
  76. requests is the same at all replicas.
  77. There is an additional requirement that needs to be ensured by Byzantine
  78. tolerant state machine replication: only requests (called transactions in the
  79. Tendermint terminology) proposed by clients are executed. In Tendermint,
  80. transaction verification is the responsibility of the service that is being
  81. replicated; upon receiving a transaction from the client, the Tendermint
  82. process will ask the service if the request is valid, and only valid requests
  83. will be processed.
  84. \subsection{Consensus} \label{sec:consensus}
  85. Tendermint solves state machine replication by sequentially executing consensus
  86. instances to agree on each block of transactions that are
  87. then executed by the service being replicated. We consider a variant of the
  88. Byzantine consensus problem called Validity Predicate-based Byzantine consensus
  89. that is motivated by blockchain systems~\cite{GLR17:red-belly-bc}. The problem
  90. is defined by an agreement, a termination, and a validity property.
  91. \begin{itemize} \item \emph{Agreement:} No two correct processes decide on
  92. different values. \item \emph{Termination:} All correct processes
  93. eventually decide on a value. \item \emph{Validity:} A decided value
  94. is valid, i.e., it satisfies the predefined predicate denoted
  95. \emph{valid()}. \end{itemize}
  96. This variant of the Byzantine consensus problem has an application-specific
  97. \emph{valid()} predicate to indicate whether a value is valid. In the context
  98. of blockchain systems, for example, a value is not valid if it does not
  99. contain an appropriate hash of the last value (block) added to the blockchain.