pub trait LaneMessageVerifier<Payload> {
    // Required method
    fn verify_message(
        lane: &LaneId,
        outbound_data: &OutboundLaneData,
        payload: &Payload
    ) -> Result<(), VerificationError>;
}
Expand description

Lane message verifier.

Runtime developer may implement any additional validation logic over message-lane mechanism. E.g. if lanes should have some security (e.g. you can only accept Lane1 messages from Submitter1, Lane2 messages for those who has submitted first message to this lane, disable Lane3 until some block, …), then it may be built using this verifier.

Any fee requirements should also be enforced here.

Required Methods§

source

fn verify_message( lane: &LaneId, outbound_data: &OutboundLaneData, payload: &Payload ) -> Result<(), VerificationError>

Verify message payload and return Ok(()) if message is valid and allowed to be sent over the lane.

Object Safety§

This trait is not object safe.

Implementors§