pub enum EncryptError {
WrongCiphertextLength,
PlaintextTooLong,
AadTooLong,
WrongKeyLength,
WrongTagLength,
WrongNonceLength,
Unknown,
}Expand description
Error that can occur during encryption.
Variants§
WrongCiphertextLength
The ciphertext buffer has the wrong length.
PlaintextTooLong
The plaintext is too long for this algorithm or implementation.
AadTooLong
The AAD is too long for this algorithm or implementation.
WrongKeyLength
The key has the wrong length.
WrongTagLength
The tag has the wrong length.
WrongNonceLength
The nonce has the wrong length.
Unknown
An unknown error occurred during encryption.
Trait Implementations§
Source§impl Debug for EncryptError
impl Debug for EncryptError
Source§impl Display for EncryptError
impl Display for EncryptError
Source§impl From<EncryptError> for EncryptError
impl From<EncryptError> for EncryptError
Source§fn from(value: EncryptError) -> Self
fn from(value: EncryptError) -> Self
Converts to this type from the input type.
Source§impl PartialEq for EncryptError
impl PartialEq for EncryptError
impl Eq for EncryptError
impl StructuralPartialEq for EncryptError
Auto Trait Implementations§
impl Freeze for EncryptError
impl RefUnwindSafe for EncryptError
impl Send for EncryptError
impl Sync for EncryptError
impl Unpin for EncryptError
impl UnwindSafe for EncryptError
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