pub enum VaultError {
TooSmall,
BadMagic,
UnsupportedVersion(u8),
DecryptionFailed,
EncryptionFailed,
MalformedData,
Io(Error),
}Expand description
Errors that can occur during vault operations.
Variants§
TooSmall
Vault file is too small to contain a valid header.
BadMagic
Magic bytes don’t match “QVLT”.
UnsupportedVersion(u8)
Vault version is not supported.
DecryptionFailed
AES-GCM decryption failed — wrong passphrase or tampered data.
EncryptionFailed
AES-GCM encryption failed.
MalformedData
Vault data is malformed.
Io(Error)
I/O error.
Trait Implementations§
Source§impl Debug for VaultError
impl Debug for VaultError
Source§impl Display for VaultError
impl Display for VaultError
Source§impl Error for VaultError
impl Error for VaultError
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()
Auto Trait Implementations§
impl Freeze for VaultError
impl !RefUnwindSafe for VaultError
impl Send for VaultError
impl Sync for VaultError
impl Unpin for VaultError
impl UnsafeUnpin for VaultError
impl !UnwindSafe for VaultError
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