Documentation

CslibFrontier.Computability.Distributed.Byzantine.OralMessages

Byzantine agreement against one fault #

The protocol om1 solves Byzantine agreement against one Byzantine fault among n ≥ 4 processes in two rounds. In round 1 every process sends its input to everyone; in round 2 every process relays everything it received. Process i then estimates the input of each k as the strict majority w k of the n - 1 relays from the processes j ≠ k of what k sent them, and decides the strict majority of w, ties going to false.

With at most one fault, a correct k is reported correctly by at least n - 2 > (n - 1) / 2 relays, so every correct process computes w k = x k; a faulty k is relayed only by correct processes, so all correct processes compute the same w k. Agreement follows, and validity because at least n - 1 > n / 2 entries of w are correct inputs. This is the single-fault procedure of Pease, Shostak and Lamport, §2 (there for n = 4), generalized to n ≥ 4 and followed by a majority vote, as in the oral messages algorithm OM(1) Lamport, Shostak and Pease, §3, Theorem 1, except that a process estimates its own input from the relays as it does every other.

Together with the node bound this settles the single-fault case: exists_solvesByzantineAgreement_one_iff says that n processes can solve Byzantine agreement against one fault in R ≥ 2 rounds exactly when n ≤ 1 or n ≥ 4. The recursive algorithm OM(t) for any number of faults, and the proof that om1 decides as its case t = 1, are in CslibFrontier.Computability.Distributed.Byzantine.RecursiveOralMessages.

Main definitions #

Main results #

References #

The local state of a process running om1.

  • input : Bool

    The process's own input.

  • heard : P → Bool

    heard j: the bit received from j in round 1.

  • report : P → P → Bool

    report j k: the bit that j claimed in round 2 to have received from k in round 1.

Two-round Byzantine agreement against one fault. Round 1 sends the input to everyone, round 2 relays the bits received in round 1, and later rounds change nothing. The decision is the strict majority over k of the strict majority w k of the relays report j k by the processes j ≠ k, ties going to false.

theorem Cslib.Distributed.Byzantine.om1_state_add_two {P : Type u_1} [Fintype P] [DecidableEq P] (F : Finset P) (adv : ℕ → P → P → P → Bool) (x : P → Bool) (i : P) (r : ℕ) :
(om1 P).state F adv x (r + 2) i = (om1 P).state F adv x 2 i

om1 changes nothing after round 2.

Oral messages against one fault: om1 solves Byzantine agreement against one fault among n ≥ 4 processes in any R ≥ 2 rounds. It is the single-fault procedure of Pease, Shostak and Lamport, §2 (there for n = 4), generalized to n ≥ 4, followed by the majority vote of OM(1) Lamport, Shostak and Pease, Theorem 1.

theorem Cslib.Distributed.Byzantine.exists_solvesByzantineAgreement_one_iff (n : ℕ) {R : ℕ} (hR : 2 ≤ R) :
(∃ (S : Type) (M : Type) (π : Protocol (Fin n) S M), π.SolvesByzantineAgreement 1 R) ↔ n ≤ 1 ∨ 4 ≤ n

The single-fault case. For R ≥ 2, some protocol on n processes solves Byzantine agreement against one fault in R rounds exactly when n ≤ 1 or n ≥ 4: ownInput and om1 solve it, and the node bound Fischer, Lynch and Merritt, Theorem 1 excludes n = 2, 3.