#[non_exhaustive]pub struct Finding {
pub severity: Severity,
pub family: Family,
pub category: Cow<'static, str>,
pub offset: Option<u64>,
pub coordinates: Vec<Coordinate>,
pub detail: String,
}Expand description
A typed deviation from what a family’s writer would emit, carrying its severity, where it sits, and that family’s own description.
This is the projection every family produces and every renderer consumes. A family’s own taxonomy is richer — it knows that a checksum failure was a group descriptor’s rather than an inode’s, as a value rather than as a word — and that taxonomy stays with the family; what crosses into here is what a report has to render and a policy has to threshold.
A JSON record, a rendered table row, and a SARIF result are projections of this,
computed in FindingReport rather than at the edge: a projection written outside this
crate would enumerate the fields from outside, where #[non_exhaustive] blocks the
exhaustive destructure that keeps it complete, so a fact learned about a finding would
silently stop being reported.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.severity: SeverityHow serious the deviation is.
family: FamilyThe family that found it.
category: Cow<'static, str>The subsystem it was found in, in the family’s own vocabulary.
offset: Option<u64>Byte offset within the image, when the finding is at a known one. Absent where the family locates the fault by something it cannot convert — a group, an inode number, a directory entry — rather than by a place in the bytes.
coordinates: Vec<Coordinate>The family’s own coordinates, in the order it reports them. Empty when the finding is about the image as a whole.
detail: StringA human-readable description.