pub enum ExtractionError {
Io(Error),
UnsupportedFormat,
InvalidArchive(String),
PathTraversal {
path: PathBuf,
},
SymlinkEscape {
path: PathBuf,
},
HardlinkEscape {
path: PathBuf,
},
ZipBomb {
compressed: u64,
uncompressed: u64,
ratio: f64,
},
InvalidPermissions {
path: PathBuf,
mode: u32,
},
QuotaExceeded {
resource: String,
},
SecurityViolation {
reason: String,
},
}Expand description
Errors that can occur during archive extraction.
Variants§
Io(Error)
I/O operation failed.
UnsupportedFormat
Archive format is unsupported or unrecognized.
InvalidArchive(String)
Archive is corrupted or invalid.
PathTraversal
Path traversal attempt detected.
SymlinkEscape
Symlink points outside extraction directory.
HardlinkEscape
Hardlink target not in extraction directory.
ZipBomb
Potential zip bomb detected.
Fields
InvalidPermissions
File permissions are invalid or unsafe.
QuotaExceeded
Extraction quota exceeded.
SecurityViolation
Operation not permitted by security policy.
Trait Implementations§
Source§impl Debug for ExtractionError
impl Debug for ExtractionError
Source§impl Display for ExtractionError
impl Display for ExtractionError
Source§impl Error for ExtractionError
impl Error for ExtractionError
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 ExtractionError
impl !RefUnwindSafe for ExtractionError
impl Send for ExtractionError
impl Sync for ExtractionError
impl Unpin for ExtractionError
impl !UnwindSafe for ExtractionError
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