Skip to main content

expected_verdict

Function expected_verdict 

Source
pub fn expected_verdict(record: &[u8; 1664], trusted: &VerifyingKey) -> u8
Expand description

The verdict byte the hardware must write for record, given the trusted Ed25519 key.

Each check runs on the raw bytes, independently of the others, exactly as the hardware does: a bad key index still gets its Merkle and chain checks (with the index’s low 7 bits), and a bad header still gets its certificate checked. Only the combination matters for validity, but the byte pins down every bit, so the card run is checked bit for bit.