Docs Protocol
Validator
Algorithm 2. How a validator checks proposer blocks, agrees a slot on a set of proposers, executes it and votes once per cblock.
Every validator, proposer or not, runs the same loop for every slot: rebuild the proposer blocks from Rotor shreds, collect the attestations that come directly from the proposers, decide whether the slot is agreed on a set of proposers, decrypt and merge those blocks, execute the xblock, and vote once per cblock on the resulting state. Alpenglow runs unchanged on consensus slots and cblocks; only its timeouts and its Block events come from this algorithm.
Validity of a proposer block
A proposer block b(s,q) is valid if:
| Rule | |
|---|---|
| (i) | all its shreds are valid and signed by p_q, their Merkle roots match, and together with the reconstructed shreds they reproduce the Merkle root included in the received shreds |
| (ii) | the block is complete and was received before the timeout of its consensus slot |
| (iii) | it is the only block of p_q for slot s; otherwise p_q equivocated |
| (iv) | its hash matches the commitment the attestations attest to |
| (v) | its payload decrypts under the key K(s,q) from p_q's attestation, and that key matches the commitment |
| (vi) | in the first slot of a window, its parent reference is correct |
| (vii) | it respects the size, format and compute limits, and the fee-payer inclusion rate |
Agreement
A validator considers slot s agreed on the set P_s if:
| Condition | |
|---|---|
| (a) | all attestations for slot s it has received agree, and P_s is the set they attest |
| (b) | it holds the attestation of every proposer in P_s |
| (c) | P_s is a strict majority of the proposers: more than k/2, so at least 2 of 3 |
| (d) | it has seen no equivocation by any proposer in slot s |
Normally P_s holds all three proposers. A proposer that crashed is attested late by both co-proposers, the attestations still agree, and P_s holds the other two. With k = 3 a window survives one crashed proposer. A slot can be agreed while the attestation of a proposer outside P_s is still missing; if that attestation arrives and disagrees, the slot is no longer agreed.
Within a window the agreed set cannot change: a slot is executed only if it is agreed on the same set as the slot before it.
Execution
Once slot s is agreed on P_s and the validator holds valid blocks from every proposer in P_s, it:
- decrypts each of those blocks with the key from its proposer's attestation,
- merges their transactions into one deterministic order and selects what fits the slot (Ordering and selection),
- executes the resulting xblock on the state after the previous slot; the first slot of a window on the state after its parent cblock.
Blocks of proposers outside P_s are ignored. Slots execute in order, each within δblock once its blocks, its attestations and the state it builds on are present. Acrux executes through the Solana Virtual Machine, so the transactions and programs in an xblock are Solana's own.
Timeouts
When a validator emits ParentReady for the first consensus slot i0 of a window, it sets the timeouts of all four consensus slots of the window. Compared with Alpenglow a validator needs δblock more, for execution after the last block and attestation of a cblock arrive. The 2δlocal of the hash exchange come free, since attestations go directly to validators and save a hop against the blocks, which take two via Rotor. Consensus slot i times out at
T(i) = Δtimeout + (i − i0 + 1) · δcblock + δblock, δcblock = κ · δblockafter ParentReady. On Acrux Net, with Δtimeout = 750 ms, δcblock = 200 ms and δblock = 50 ms:
| Consensus slot of the window | Timeout after ParentReady |
|---|---|
| 1st | 1,000 ms |
| 2nd | 1,200 ms |
| 3rd | 1,400 ms |
| 4th | 1,600 ms |
Voting
A validator casts a notarization vote NotarVote(i, h(c_i)) for consensus slot i if, before T(i), all four slots of c_i are agreed on the same set P, and it has validated and executed the blocks of every proposer in P. The hash h(c_i) covers the state hash after execution. Otherwise it casts SkipVote(i).
In particular it votes skip when two attestations disagree. It never votes for a subset of the attested blocks.
The attestation deadline
If P does not hold all k proposers, the attestation of a proposer outside P may be missing, and the validator cannot tell whether that proposer is offline or its attestation is still on its way. So it executes the slots without delay, but holds back its vote for the first cblock of the window until it holds the attestations of all k proposers for the window's first slot, at the latest until
Deadline(i0) = ParentReady + δblock + 2δglobal + 2δlocalOn Acrux Net that is 50 + 500 + 20 = 570 ms after ParentReady. By then the attestation of every correct proposer for that slot has arrived: its ParentReady is at most δglobal later than the validator's, it completes its first block δblock later, attests at most 2δlocal after that, and the attestation travels at most δglobal. So colluding proposers cannot drop a correct co-proposer by attesting only each other. If a disagreeing attestation arrives in the meantime, the validator votes skip.
The wait happens once per window. The set cannot change after the first slot, so a validator that voted for c_(i-1) votes for c_i of the same window as soon as it has executed it. With w · δblock ≥ δblock + 2δglobal + 2δlocal (800 ms against 570 ms), the last cblock of a window with an offline proposer finalizes no later than in a window of three correct proposers.
Algorithm 2
1: P[s], x[s], σ[s] ← ⊥ for all slots s
2: b[s][q], V[s][q] ← ⊥; eq[s][q] ← false for all slots s, proposers q
3: voted[i] ← ⊥ for all consensus slots i
4: upon ParentReady(i0, ·) do
5: for i = i0, …, i0 + w/κ − 1 do
6: Timeout(i) ← now + Δtimeout + (i − i0 + 1)·κ·δblock + δblock
7: Deadline(i0) ← now + δblock + 2δglobal + 2δlocal
8: end for
9: upon now = Deadline(i0) do stop waiting for missing attestations
10: TryVote(i0)
11: upon receive new shred of proposer q for slot s from Rotor do
12: if saw equivocation evidence then eq[s][q] ← true
13: if reconstructed a valid block b(s,q) of q for slot s then
14: b[s][q] ← b(s,q)
15: TryExecute(s)
16: end if
17: upon V(s,q) = Attestation(s, q, π, K) do
18: if V[s][q] ≠ ⊥ then
19: if V(s,q) ≠ V[s][q] then eq[s][q] ← true equivocation, slashable
20: else
21: V[s][q] ← V(s,q)
22: TryExecute(s); TryVote(⌊s/κ⌋)
23: end if
24: procedure TryExecute(s)
25: i ← ⌊s/κ⌋; A ← Agreed(s)
26: if P[s] ≠ ⊥ or A = ⊥ or b[s][q] = ⊥ for some q ∈ A then return
27: if s is not the first slot of its window and P[s − 1] ≠ A then return
28: x[s] ← (b(s,q)) for q ∈ A
29: T_q ← Dec(V[s][q].K, b[s][q]) for all q ∈ A
30: if some T_q is invalid or h(b[s][q]) ≠ V[s][q].π[q] for some q ∈ A then return
31: if s is the first slot of its window then
32: ĉ ← the most common b[s][q].parent over q ∈ A, ties to the lowest q
33: if σ[ĉ] = ⊥ then return parent not executed yet
34: σ̂ ← σ[ĉ]; par[i] ← ĉ
35: else
36: σ̂ ← σ[s − 1]; if s = κi then par[i] ← (i − 1, h(c_(i-1)))
37: end if
38: σ[s] ← Execute(σ̂, Merge(s, (T_q) for q ∈ A)) Algorithm 4
39: P[s] ← A
40: if s is the last slot of c_i then TryVote(i)
41: TryExecute(s + 1) slot s + 1 may be complete already
42: end procedure
43: procedure TryVote(i) emits Block for c_i, at most once
44: if voted[i] ≠ ⊥ or P[s] = ⊥ or Agreed(s) ≠ P[s] for a slot s of c_i then return
45: first ← i is the first consensus slot of its window
46: if first and V[s0][q] = ⊥ for some q and now < Deadline(i) then return wait
47: if not first and voted[i − 1] = ⊥ then return vote in order
48: voted[i] ← P[s] for the slots s of c_i
49: c_i ← (par[i], (x_s) for the slots of c_i, h(σ[last slot of c_i]))
50: emit Block(i, h(c_i), par[i])
51: TryVote(i + 1) c_(i+1) may be waiting for this vote
52: end procedure
53: function Agreed(s) the accepted proposers of slot s, or ⊥
54: if V[s][q] = ⊥ for all q, or eq[s][q] for some q then return ⊥
55: if V[s][q].π ≠ V[s][q'].π for some V[s][q], V[s][q'] ≠ ⊥ then return ⊥ all agree
56: A ← { p : π[p] ≠ ⊥ } with π = V[s][q].π for some V[s][q] ≠ ⊥
57: if |A| ≤ k/2 or V[s][q] = ⊥ for some q ∈ A then return ⊥
58: return A
59: end functions0 in line 46 is the first slot of the window. The line-by-line map from this listing to acrux-node's code is on /spec.
What a validator watches for
- Equivocation. Two different attestations from the same proposer for one slot, or shreds of two different blocks, set
eq[s][q]. The slot is not agreed and the two signed messages are the slashing proof. See the Equivocation scenario. - Disagreement. A commitment delivered to one co-proposer only produces attestations with different vectors. The slot is not agreed, the validator votes skip, and the rest of the window is skipped. See the Split commitments scenario.
- A missing proposer. Attested late by both co-proposers, it drops out of
Pand the window continues on two. See the Crash scenario.