Skip to main content

Module cert

Module cert 

Source
Expand description

Certificates (W4; docs/rhdl_ubft-view-change.md): q = f + 1 signature shares from distinct replicas over one exact key (role, view, instance, digest).

Two encodings are fixed here, as kernels, so hardware and tests agree:

  • value_block: the 128-byte SHA-512 input naming a value, "RUB2-VAL" ‖ session ‖ instance ‖ len ‖ 0^8 ‖ value, zero past len. The value digest d is its first 32 bytes. The session is inside d, so a share never transfers between runs.
  • share_context: the 48 signed bytes (sign layout v2): "RUB2" ‖ role ‖ 0 0 0 ‖ view ‖ instance ‖ d. View and instance are full 32-bit fields (upstream packs a 16-bit view into the index, UE-C7), and the role separates prepare shares from history shares.

Modules§

collector
Share collector: a certificate is q verified shares from distinct replicas over one exact key (docs/rhdl_ubft-view-change.md).

Constants§

ROLE_HISTORY
Role byte of a sealed-history share.
ROLE_PREPARE
Role byte of a prepare (certify) share.
VAL_DOMAIN
"RUB2-VAL" as a little-endian word.

Functions§

share_context
The 48 signed bytes of a share, as six little-endian words.
value_block
The 128-byte value-digest input as 16 big-endian SHA-512 words.
value_digest
The value digest from a finished SHA-512 state: bytes 0..32 as little-endian words.