Enum tendermint_light_client::predicates::errors::VerificationError[][src]

pub enum VerificationError {
    HeaderFromTheFuture {
        header_time: Time,
        now: Time,
    },
    ImplementationSpecific(String),
    NotEnoughTrust(VotingPowerTally),
    InsufficientSignersOverlap(VotingPowerTally),
    DuplicateValidator(ValidatorAddress),
    InvalidSignature {
        signature: Vec<u8>,
        validator: Box<Validator>,
        sign_bytes: Vec<u8>,
    },
    InvalidCommitValue {
        header_hash: Hash,
        commit_hash: Hash,
    },
    InvalidNextValidatorSet {
        header_next_validators_hash: Hash,
        next_validators_hash: Hash,
    },
    InvalidValidatorSet {
        header_validators_hash: Hash,
        validators_hash: Hash,
    },
    NonIncreasingHeight {
        got: Height,
        expected: Height,
    },
    NonMonotonicBftTime {
        header_bft_time: Time,
        trusted_header_bft_time: Time,
    },
    NotWithinTrustPeriod {
        expires_at: Time,
        now: Time,
    },
}
Expand description

The various errors which can be raised by the verifier component, when validating or verifying a light block.

Variants

HeaderFromTheFuture

The header is from the future

Show fields

Fields of HeaderFromTheFuture

header_time: Time

Time in the header

now: Time

Current time

ImplementationSpecific(String)

Implementation specific error, for the purpose of extensibility

NotEnoughTrust(VotingPowerTally)

Not enough trust because insufficient validators overlap

InsufficientSignersOverlap(VotingPowerTally)

Insufficient signers overlap

DuplicateValidator(ValidatorAddress)

Duplicate validator in commit signatures

InvalidSignature

Invalid commit signature

Show fields

Fields of InvalidSignature

signature: Vec<u8>

Signature as a byte array

validator: Box<Validator>

Validator which provided the signature

sign_bytes: Vec<u8>

Bytes which were signed

InvalidCommitValue

Invalid commit

Show fields

Fields of InvalidCommitValue

header_hash: Hash

Header hash

commit_hash: Hash

Commit hash

InvalidNextValidatorSet

Hash mismatch for the next validator set

Show fields

Fields of InvalidNextValidatorSet

header_next_validators_hash: Hash

Next validator set hash

next_validators_hash: Hash

Validator set hash

InvalidValidatorSet

Hash mismatch for the validator set

Show fields

Fields of InvalidValidatorSet

header_validators_hash: Hash

Hash of validator set stored in header

validators_hash: Hash

Actual hash of validator set in header

NonIncreasingHeight

Unexpected header of non-increasing height compared to what was expected

Show fields

Fields of NonIncreasingHeight

got: Height

Actual height of header

expected: Height

Expected minimum height

NonMonotonicBftTime

BFT Time between the trusted state and a header does not increase monotonically

Show fields

Fields of NonMonotonicBftTime

header_bft_time: Time

BFT time of the untrusted header

trusted_header_bft_time: Time

BFT time of the trusted header

NotWithinTrustPeriod

Trusted state not within the trusting period

Show fields

Fields of NotWithinTrustPeriod

expires_at: Time

Expiration time of the header

now: Time

Current time

Implementations

Add additional context (i.e. include a source error and capture a backtrace). You can convert the resulting Context into an Error by calling .into().

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Deserialize this value from the given Serde deserializer. Read more

Formats the value using the given formatter. Read more

The lower-level source of this error, if any. Read more

🔬 This is a nightly-only experimental API. (backtrace)

Returns a stack backtrace, if available, of where this error occurred. Read more

👎 Deprecated since 1.42.0:

use the Display impl or to_string()

👎 Deprecated since 1.33.0:

replaced by Error::source, which can support downcasting

Whether this error means that the light block cannot be trusted w.r.t. the latest trusted state. Read more

Whether this error means that the light block has expired, ie. it’s outside of the trusting period. Read more

Whether this error means that a timeout occured when querying a node. Read more

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Compare self to key and return true if they are equal.

Performs the conversion.

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more

Instruments this type with the current Span, returning an Instrumented wrapper. Read more

Performs the conversion.

The alignment of pointer.

The type for initializers.

Initializes a with the given initializer. Read more

Dereferences the given pointer. Read more

Mutably dereferences the given pointer. Read more

Drops the object pointed to by the given pointer. Read more

Should always be Self

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

🔬 This is a nightly-only experimental API. (toowned_clone_into)

recently added

Uses borrowed data to replace owned data, usually by cloning. Read more

Converts the given value to a String. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.