#[non_exhaustive]pub enum VerifyError {
Header(&'static str),
Version,
Malformed(&'static str),
UnknownKey,
KeyBounds,
Audience,
Interval,
ClockLead,
Expired,
Digest,
Signature,
Replay,
}Expand description
Why a request failed verification. The text is fixed and never quotes the request.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Header(&'static str)
A required X-Mkit-Hook-* header is absent or sent twice.
Version
X-Mkit-Hook-Version is not 1.
Malformed(&'static str)
A header value is not in its canonical form.
UnknownKey
The key id is not in the key list.
KeyBounds
The request was created outside the key’s validity bounds.
Audience
The audience is not this hook service’s origin.
Interval
The validity interval is not positive, or exceeds 300,000 ms.
ClockLead
The request was created more than 30 s ahead of this clock.
Expired
The request has expired.
Digest
The digest does not match the body.
Signature
The signature does not verify.
Replay
The nonce was already used inside its window.
Trait Implementations§
Source§impl Clone for VerifyError
impl Clone for VerifyError
Source§fn clone(&self) -> VerifyError
fn clone(&self) -> VerifyError
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for VerifyError
Source§impl Debug for VerifyError
impl Debug for VerifyError
Source§impl Display for VerifyError
impl Display for VerifyError
impl Eq for VerifyError
Source§impl Error for VerifyError
impl Error for VerifyError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Source§impl PartialEq for VerifyError
impl PartialEq for VerifyError
impl StructuralPartialEq for VerifyError
Auto Trait Implementations§
impl Freeze for VerifyError
impl RefUnwindSafe for VerifyError
impl Send for VerifyError
impl Sync for VerifyError
impl Unpin for VerifyError
impl UnsafeUnpin for VerifyError
impl UnwindSafe for VerifyError
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more