Chapter 05 · ~17 min
Signatures & certificates
Real BLS in your browser — and the 160 bytes that make finality portable.
What you’ll walk away with
- What a vote physically is — and why every validator carries two different keys
- Why a 40-validator certificate weighs the same as a 4-validator one (the BLS addition trick)
- How a certificate turns “trust the network” into “verify 160 bytes”, forever
- Multisig vs. threshold: two ways for a committee to hold its pen — a product tradeoff, not crypto trivia
Fair warning of the fun kind: every cryptographic operation on this page is real. Real BLS12-381 keys, real signatures, real aggregation, running in your browser in the same configuration our node uses. Nothing is mocked. If you tamper with a byte, actual mathematics will notice.
A vote, under the microscope
Chapter 4 treated votes as colored dots. Zoom in. A notarize or finalize vote is a
digital signature over a precise, domain-separated message — roughly “finalize,
epoch 7, view 1337, block digest ab12…”, prefixed with a namespace so a vote for
this chain, this protocol version, can never be mistaken for anything else. A
validator’s vote is those bytes plus a signature; nothing more.
Each of our validators actually carries two keypairs, doing two different jobs:
- an ed25519 key — its network identity. Peer connections authenticate with it; it answers “am I talking to the real Basil?”
- a BLS12-381 key — its consensus voting key. Every vote is signed with it; it answers “did Basil really vouch for this block?”
Why not one key for both? Because the jobs want different superpowers. Ed25519 is fast and boring — perfect for authenticating a connection. BLS signatures are slower, but they can do something ed25519 fundamentally can’t, and the entire economics of committee consensus rests on it.
The addition trick
A BLS signature is a point on an elliptic curve. Points on a curve can be added together. And BLS’s special ingredient — a bilinear pairing — makes the following astonishing equation hold:
verify(sig_theodora + sig_zoe + sig_justinian, message, pk_theodora + pk_zoe + pk_justinian) = true
Add the signatures, add the public keys, and the sum verifies like a single signature. So when 3 validators — or 27, or a thousand — sign the same finalize message, the wire doesn’t carry a bag of signatures. It carries one 96-byte point that simultaneously proves all of them signed. That’s aggregation, and it’s why “collect a quorum of votes” doesn’t get heavier as committees grow.
(How the pairing actually works is genuinely deep mathematics — and genuinely optional. The property above is all this guide needs, and all most engineers ever need.)
Try it. Below are our four validators with real keypairs — public keys are 48 bytes, signatures 96, exactly our node’s MinPk flavor. Sign as everyone, then: edit the message after signing and watch every signature die (a signature binds exact bytes). Let Justinian’s signature get tampered — one flipped byte, anywhere, is fatal, and an aggregate that includes it rots too. Then aggregate the honest votes and read the size line.
For the suspicious: can’t I forge an aggregate with a crafted key?
Sharp instinct — naive key aggregation has a classic trap called the rogue-key attack: an attacker who gets to register an arbitrary public key can craft one that cancels out other participants’ keys inside the sum. The standard defense is proof of possession: you may only register a key after proving you hold its secret. Real deployments (including the BLS standards and the libraries our stack builds on) bake this in. In this guide all keys are honest by construction, so the demos skip the ceremony — but if you ever design key registration, remember this trap exists.
Certificates: consensus you can carry
Now the payoff. In chapter 4, “a quorum of finalize votes” was an event you watched happen live. Aggregate those votes and staple on a little metadata, and the event becomes a thing — a finalization certificate: a self-contained, portable, eternally checkable proof that the committee finalized this block. Hand it to someone who wasn’t in the room — a light client, a bridge, an auditor, a future version of the node itself — and they can verify it with no network, no trust, and no conversation. Consensus, to go.
Our node takes this seriously in a very concrete way. The consensus library keeps certificates in its own archives, in its own encoding — and it ships breaking releases monthly. Certificates are the one consensus artifact the chain may need forever. So at the moment of finalization, the node converts each certificate into its own sovereign format, under its own control: the library’s archives are a rebuildable cache; the sovereign record is the durable truth. A library upgrade can never strand certificate history.
Below is that exact format, byte for byte, built live from real signatures: epoch 7, view 1337, block #421, signed by Theodora, Zoe, and Justinian (Basil napped — 3-of-4 is a quorum, and life goes on). Your missions:
- Read the bytes. Click fields in the dump or the table. Notice what’s missing: the block height. The committee signed a digest; height is chain metadata the node indexes separately. (Also notice the little version and scheme fields — that’s evolution-proofing, chapter 8’s subject.)
- Flip one digest byte. Parsing still succeeds, the quorum still looks fine — and step 3 catches the lie. The signature bound the original bytes.
- Claim Basil signed (set his bitmap bit without his signature). Quorum now claims 4-of-4 — and the cryptography refuses: an aggregate can’t be verified against keys that didn’t participate. A certificate cannot lie about who signed.
- Drop to 2 honest signers. Now the cryptography is genuine — two validators really signed — but 2 is not a quorum. Valid signatures are necessary, not sufficient. (You met this exact arithmetic in chapter 2.)
Two ways to hold the committee’s pen
The certificate you just inspected is a multi-signature: an aggregated signature plus a bitmap naming exactly who signed. That’s one of two ways a committee can hold its pen — both deliberate designs, solving for different verifiers:
| Multisig + bitmap | Threshold | |
|---|---|---|
| Committee key | a list of public keys | one group public key |
| Verifier must know | the validator set for that epoch | just the one key |
| Who signed? | named in the bitmap — votes are attributable | invisible by design |
| Setup | none — a committee is just a list of keys | a DKG ceremony per committee |
| Great for | validators, full nodes, misbehavior evidence | light clients, bridges |
Multisig’s superpowers are zero ceremony (onboarding a validator = adding a key to a list) and attributability — which the evidence section below turns into a weapon. Its cost: whoever verifies must know the committee — fine for validators and full nodes, which track it anyway.
Threshold flips the tradeoff. The committee holds shares of one secret that has
never existed in any single place, and any t of them can jointly produce the
group signature — indistinguishable from a single signer’s work. A verifier holds
one 48-byte key and never learns who participated, or even how big the committee is.
That’s the light-client story. And it’s why the certificate you inspected carries a
scheme field: certificates declare which pen signed them, so a chain can adopt
either — or move between them — without breaking its history.
The demo below deals shares to our four validators with threshold t = 3 — the
quorum, and that’s no coincidence: “a certificate exists” and “a quorum signed”
become the same fact. Your missions: combine the default trio and verify against
the group key. Then swap Basil in and Justinian out — identical bytes. Any trio
produces the same signature, because any trio reconstructs the same never-assembled
secret. Then try two shares and watch the math shrug.
DKG and VRFs, one gentle paragraph each
DKG (distributed key generation): the demo above used a “dealer” who briefly knew the whole secret — unacceptable in production, since the dealer could sign anything alone, forever. A DKG is a ceremony in which the committee jointly generates the shares such that the full secret never exists anywhere: everyone contributes randomness, everyone verifies everyone’s contributions, and the group key pops out at the end. It’s operationally the expensive part of threshold schemes (it must re-run when the committee changes) — the price a network pays for threshold’s verifier-side simplicity.
VRFs (verifiable random functions): the same threshold machinery yields a bonus — a random value per view that nobody can predict or bias, but everyone can verify. That’s the ingredient for unpredictable leader election. A plain round-robin rotation is perfectly sound, just predictable: anyone can compute who leads view 12,041 and aim traffic at them a week in advance. A VRF-based elector closes that door. Which rotation a network runs is a deployment choice — readable, like everything in this section, off the concrete types in the code.
Signatures as handcuffs
One more property, and it closes a loop from two chapters back. Because our votes are attributable — every signature names its signer — a validator that equivocates hands the network the evidence against itself. Justinian signs “notarize block A, view 9” and also “notarize block B, view 9”? Each message alone looks legitimate. Together, they are a signed confession — transferable, verifiable by anyone, deniable by no one. Remember the ⚠ lines in chapter 4’s event log, and the fork puzzle’s small print in chapter 2: this is the mechanism. Our node surfaces exactly such conflicting-vote evidence, with the culprit’s identity, in its logs, metrics, and status endpoint. What to do about a caught validator — slashing, ejection, a stern meeting — is deliberately a policy question left open; the protocol’s job is only to make guilt undeniable.
The four things to keep
- A vote is a BLS signature over a domain-separated message; identity (ed25519) and voting (BLS) are separate keys with separate jobs.
- Signatures and public keys add — so a quorum’s worth of votes travels as one 96-byte signature, at any committee size.
- A certificate is consensus made portable: ~160 self-describing bytes that prove finality to anyone, forever — which is why the node stores them in its own sovereign format.
- Multisig names its signers (evidence!) but verifiers need the member list; threshold shows one key to the world but needs a DKG — two pens for different verifiers, and every certificate’s
schemefield says which one signed it.
Where this lives in our stack
- Which signature scheme and which leader rotation the network runs right now — along with the rationale and the two-key setup — is stated at the top of lib/consensus/core/src/types.rs. This guide deliberately teaches both pens; the code is the source of truth for which one is in the committee’s hand, and you can now read that doc comment and nod along. The keygen tool that mints validator keypairs is tools/consensus-keygen.
- The certificate you dissected is lib/wire/src/finality_certificate.rs, field for field — including the module doc explaining the sovereign-format reasoning and why height is deliberately external. Its encoding is frozen by golden tests (lib/wire/goldens/): released bytes never change, new needs get new versions.
- Every finalization certificate is captured into the node’s finality store
(lib/consensus/execution/src/finality_store.rs),
whose certified watermark — the highest height provably finalized by quorum —
is reported as
finality_certified_heightin the node’s status endpoint. That number is this chapter, live, on every running validator. - Conflicting-vote evidence — the “signed confession” — is real machinery in the node’s activity observer; you’ll find the fault counters in the consensus metrics.
Next: you now know the protocol (chapter 4) and the artifacts it signs (this chapter). Time to meet the machine both run on: commonware — the library ideology, the dozen crates we pin, the deterministic runtime that makes our tests reproducible, and the surprisingly small seam where our node plugs in.