Skip to main content

allow_report/artifacts/
explain.rs

1use allow_core::{AllowEntry, Finding, MatchOutcome};
2
3use crate::InventoryContext;
4
5#[derive(Debug, Clone, Copy, Default)]
6pub struct EvidenceReference<'a> {
7    pub raw: &'a str,
8    pub prefix: Option<&'a str>,
9    pub target: Option<&'a str>,
10    pub status: &'a str,
11    pub category: &'a str,
12    pub message: &'a str,
13}
14
15#[derive(Debug, Clone, Copy)]
16pub struct ExplainReport<'a> {
17    pub inventory: InventoryContext<'a>,
18    pub entry: &'a AllowEntry,
19    pub selector_precision: u32,
20    pub broad_scope: bool,
21    pub current_findings: &'a [Finding],
22    pub match_outcomes: &'a [MatchOutcome],
23    pub evidence_references: &'a [EvidenceReference<'a>],
24    pub link_references: &'a [EvidenceReference<'a>],
25    pub suggested_actions: &'a [String],
26    pub proof_commands: &'a [String],
27}