Function cumulus_primitives_core::relay_chain::check_candidate_backing
source ยท pub fn check_candidate_backing<H>(
candidate_hash: CandidateHash,
validity_votes: &[ValidityAttestation],
validator_indices: &BitSlice<u8>,
signing_context: &SigningContext<H>,
group_len: usize,
validator_lookup: impl Fn(usize) -> Option<Public>,
) -> Result<usize, ()>
Expand description
Verify the backing of the given candidate.
Provide a lookup from the index of a validator within the group assigned to this para, as opposed to the index of the validator within the overall validator set, as well as the number of validators in the group.
Also provide the signing context.
Returns either an error, indicating that one of the signatures was invalid or that the index was out-of-bounds, or the number of signatures checked.