Enum hpke_rs_crypto::error::Error
source · [−]pub enum Error {
HpkeInvalidOutputLength,
UnknownKdfAlgorithm,
KemInvalidSecretKey,
KemInvalidPublicKey,
UnknownKemAlgorithm,
UnknownAeadAlgorithm,
AeadInvalidNonce,
AeadOpenError,
AeadInvalidCiphertext,
InsufficientRandomness,
CryptoLibraryError(String),
}
Expand description
Errors thrown by crate::HpkeCrypto
trait implementations.
Variants
HpkeInvalidOutputLength
The output length is invalid (too large).
UnknownKdfAlgorithm
Unknown or unsupported KDF algorithm.
KemInvalidSecretKey
Invalid secret key for the KEM.
KemInvalidPublicKey
Invalid public key for the KEM.
UnknownKemAlgorithm
Unknown or unsupported KEM algorithm,
UnknownAeadAlgorithm
Unknown or unsupported AEAD algorithm.
AeadInvalidNonce
Invalid nonce for the AEAD algorithm.
AeadOpenError
Error opening an AEAD cipher text.
AeadInvalidCiphertext
Invalid cipher text for the AEAD algorithm.
InsufficientRandomness
Insufficient randomness to perform the operation.
CryptoLibraryError(String)
A crypto library error.
Trait Implementations
sourceimpl Error for Error
impl Error for Error
1.30.0 · sourcefn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
The lower-level source of this error, if any. Read more
sourcefn backtrace(&self) -> Option<&Backtrace>
fn backtrace(&self) -> Option<&Backtrace>
🔬 This is a nightly-only experimental API. (
backtrace
)Returns a stack backtrace, if available, of where this error occurred. Read more
1.0.0 · sourcefn description(&self) -> &str
fn description(&self) -> &str
👎 Deprecated since 1.42.0:
use the Display impl or to_string()
Auto Trait Implementations
impl RefUnwindSafe for Error
impl Send for Error
impl Sync for Error
impl Unpin for Error
impl UnwindSafe for Error
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more