Enum age::DecryptError
source · [−]pub enum DecryptError {
DecryptionFailed,
ExcessiveWork {
required: u8,
target: u8,
},
InvalidHeader,
InvalidMac,
Io(Error),
KeyDecryptionFailed,
MissingPlugin {
binary_name: String,
},
NoMatchingKeys,
Plugin(Vec<PluginError>),
UnknownFormat,
}
Expand description
The various errors that can be returned during the decryption process.
Variants
DecryptionFailed
The age file failed to decrypt.
ExcessiveWork
Fields
required: u8
The work factor required to decrypt.
target: u8
The target work factor for this device (around 1 second of work).
The age file used an excessive work factor for passphrase encryption.
InvalidHeader
The age header was invalid.
InvalidMac
The MAC in the age header was invalid.
Io(Error)
An I/O error occurred during decryption.
KeyDecryptionFailed
Failed to decrypt an encrypted key.
MissingPlugin
Fields
binary_name: String
The plugin’s binary name.
plugin
only.A required plugin could not be found.
NoMatchingKeys
None of the provided keys could be used to decrypt the age file.
Plugin(Vec<PluginError>)
plugin
only.Errors from a plugin.
UnknownFormat
An unknown age format, probably from a newer version.
Trait Implementations
sourceimpl Clone for DecryptError
impl Clone for DecryptError
sourceimpl Debug for DecryptError
impl Debug for DecryptError
sourceimpl Display for DecryptError
impl Display for DecryptError
sourceimpl Error for DecryptError
impl Error for DecryptError
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>
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
use the Display impl or to_string()
sourceimpl From<Error> for DecryptError
impl From<Error> for DecryptError
sourceimpl From<Error> for DecryptError
impl From<Error> for DecryptError
sourceimpl From<Error> for DecryptError
Available on crate feature ssh
only.
impl From<Error> for DecryptError
ssh
only.Auto Trait Implementations
impl !RefUnwindSafe for DecryptError
impl Send for DecryptError
impl Sync for DecryptError
impl Unpin for DecryptError
impl !UnwindSafe for DecryptError
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more