Skip to main content

view_change_evidence_matches_parent

Function view_change_evidence_matches_parent 

Source
pub(crate) fn view_change_evidence_matches_parent<T: NodeType>(
    proposal: &Proposal<T>,
) -> Result<Option<&TimeoutEvidence<T>>, MalformedProposal>
Expand description

A proposal extends an earlier view, and skips views only with a timeout certificate for the view immediately before it.

Returns the certificate to verify the signatures on, or None when the proposal follows its parent directly and carries none.

A proposal may carry a certificate it does not need: a leader holding one for the view before builds on its lock, which can be that view’s own certificate. It is checked all the same, since it becomes part of the block.

The parent view being earlier is what the walks over stored proposals descend on, and, like the rest of what a proposal says about its parent, it is covered by no signature of the proposer’s own.