[][src]Enum koibumi_core::crypto::DecryptError

pub enum DecryptError {
    UnsupportedCurve(u16),
    InvalidKeyLength {
        x_len: usize,
        y_len: usize,
    },
    InvalidMacKeyLength(InvalidKeyLength),
    InvalidSecretKey,
    MacError(MacError),
    Secp256k1Error(Error),
    BlockModeError(BlockModeError),
}

This error indicates that the decryption failed.

Variants

UnsupportedCurve(u16)

Indicates that the object was encrypted by using a curve unsupported by this implementation.

InvalidKeyLength

Indicates that at least one of the lengths of the components of the public key was invalid. The actual lengths of the components are returned as payloads of this variant.

Fields of InvalidKeyLength

x_len: usize

The actual length of the component x.

y_len: usize

The actual length of the component y.

InvalidMacKeyLength(InvalidKeyLength)

An error was caught during initialization of the MAC verifier. The actual error caught is returned as a payload of this variant.

InvalidSecretKey

Indicates that the secret key is invalid.

MacError(MacError)

An error was caught during verification of the MAC. The actual error caught is returned as a payload of this variant.

Secp256k1Error(Error)

An error was caught during a process using secp256k1. The actual error caught is returned as a payload of this variant.

BlockModeError(BlockModeError)

An error was caught during a process using a block mode. The actual error caught is returned as a payload of this variant.

Trait Implementations

impl Clone for DecryptError[src]

impl Debug for DecryptError[src]

impl Display for DecryptError[src]

impl Error for DecryptError[src]

impl From<BlockModeError> for DecryptError[src]

impl From<DecryptError> for DecryptError[src]

impl From<Error> for DecryptError[src]

impl From<InvalidKeyLength> for DecryptError[src]

impl From<MacError> for DecryptError[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.