Trait sc_network::warp_request_handler::WarpSyncProvider[][src]

pub trait WarpSyncProvider<B: BlockT>: Send + Sync {
    fn generate(
        &self,
        start: B::Hash
    ) -> Result<EncodedProof, Box<dyn Error + Send + Sync>>;
fn verify(
        &self,
        proof: &EncodedProof,
        set_id: SetId,
        authorities: AuthorityList
    ) -> Result<VerificationResult<B>, Box<dyn Error + Send + Sync>>;
fn current_authorities(&self) -> AuthorityList; }
Expand description

Warp sync backend. Handles retrieveing and verifying warp sync proofs.

Required methods

Generate proof starting at given block hash. The proof is accumulated until maximum proof size is reached.

Verify warp proof agains current set of authorities.

Get current list of authorities. This is supposed to be genesis authorities when starting sync.

Implementors