pub enum KeyError {
SpkiError(Error),
EllipticCurveError(EllipticCurveError),
SignatureError(SignatureError),
AeadError(AeadError),
NonceLengthError(ReceivedExpectedError<usize, usize>),
UnsupportedOperation,
}Expand description
Errors from key provider operations.
Deliberately does not derive Errorizable: this module builds without
the derive feature, so the message strings live in exactly one place –
the impl_error_display! block below.
Variants§
SpkiError(Error)
SPKI encoding/decoding error
EllipticCurveError(EllipticCurveError)
Elliptic curve operation error
SignatureError(SignatureError)
Signature/ECDSA error (e.g., invalid key bytes)
AeadError(AeadError)
AEAD encryption/decryption error
NonceLengthError(ReceivedExpectedError<usize, usize>)
Nonce length mismatch
UnsupportedOperation
Operation not supported by this key provider
Trait Implementations§
Source§impl Error for KeyError
impl Error for KeyError
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 From<Error> for KeyError
Available on crate feature signature only.
impl From<Error> for KeyError
Available on crate feature
signature only.Source§fn from(err: EllipticCurveError) -> Self
fn from(err: EllipticCurveError) -> Self
Converts to this type from the input type.
Source§impl From<Error> for KeyError
Available on crate feature signature only.
impl From<Error> for KeyError
Available on crate feature
signature only.Source§fn from(err: SignatureError) -> Self
fn from(err: SignatureError) -> Self
Converts to this type from the input type.
Source§impl From<KeyError> for TightBeamError
Available on crate feature crypto only.
impl From<KeyError> for TightBeamError
Available on crate feature
crypto only.Auto Trait Implementations§
impl !RefUnwindSafe for KeyError
impl !UnwindSafe for KeyError
impl Freeze for KeyError
impl Send for KeyError
impl Sync for KeyError
impl Unpin for KeyError
impl UnsafeUnpin for KeyError
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
impl<T> InjectedError for T
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more