VerificationReport

Struct VerificationReport 

Source
pub struct VerificationReport {
    pub status: VerificationStatus,
    pub integrity_status: CheckStatus,
    pub security_status: CheckStatus,
    pub issues: Vec<VerificationIssue>,
    pub total_entries: usize,
    pub suspicious_entries: usize,
    pub total_size: u64,
    pub format: ArchiveType,
}
Expand description

Result of archive verification.

Generated by verify_archive(), contains security and integrity checks performed without extracting files to disk.

§Examples

use exarch_core::SecurityConfig;
use exarch_core::VerificationStatus;
use exarch_core::verify_archive;

let config = SecurityConfig::default();
let report = verify_archive("archive.tar.gz", &config)?;

if report.status == VerificationStatus::Pass {
    println!("Archive is safe to extract");
} else {
    eprintln!("Security issues found:");
    for issue in report.issues {
        eprintln!("  [{}] {}", issue.severity, issue.message);
    }
}

Fields§

§status: VerificationStatus

Overall verification status

§integrity_status: CheckStatus

Integrity check result

§security_status: CheckStatus

Security check result

§issues: Vec<VerificationIssue>

List of all issues found (sorted by severity)

§total_entries: usize

Total entries scanned

§suspicious_entries: usize

Entries flagged as suspicious

§total_size: u64

Total uncompressed size

§format: ArchiveType

Archive format

Implementations§

Source§

impl VerificationReport

Source

pub fn is_safe(&self) -> bool

Returns true if the archive is safe (no critical or high severity issues).

Source

pub fn has_critical_issues(&self) -> bool

Returns true if there are any critical severity issues.

Source

pub fn issues_by_severity( &self, severity: IssueSeverity, ) -> Vec<&VerificationIssue>

Returns issues of a specific severity level.

Trait Implementations§

Source§

impl Clone for VerificationReport

Source§

fn clone(&self) -> VerificationReport

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for VerificationReport

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.