pub struct RevocationSnapshot {
pub epoch: u64,
pub root_hash: [u8; 32],
pub issued_at_unix_ms: u64,
pub revoked: BTreeSet<RevocationViewSubject>,
}Expand description
Immutable snapshot of the revocation set at a particular epoch.
Snapshots are produced by the federation gossip task from the most
recent verified signed epoch root and the leaf set the embedding kernel
has materialised locally. Once installed in a RevocationView they
are read-only; updates always go through a fresh
RevocationView::install_if_newer call.
Fields§
§epoch: u64Monotone epoch counter advertised by the carried signed root.
root_hash: [u8; 32]Hash of the carried signed root. Verifiers use this for diagnostics (e.g. correlating a deny verdict with the snapshot it was evaluated against); the kernel-core itself does not re-verify it.
issued_at_unix_ms: u64Unix milliseconds at which the carried signed root was issued. Verifiers MUST gate against their own freshness window before trusting the snapshot for fail-closed dispatch.
revoked: BTreeSet<RevocationViewSubject>Sorted set of revoked subjects at this epoch. Ordered for deterministic equality and serialisation.
Implementations§
Source§impl RevocationSnapshot
impl RevocationSnapshot
Sourcepub fn empty() -> Self
pub fn empty() -> Self
The empty sentinel snapshot (epoch = 0, no subjects, issued at
0). Returned by RevocationView::new before any gossip update
has installed a real epoch root.
Sourcepub fn is_revoked(&self, subject: &RevocationViewSubject) -> bool
pub fn is_revoked(&self, subject: &RevocationViewSubject) -> bool
Returns true when subject is present in the snapshot’s
revocation set.
Trait Implementations§
Source§impl Clone for RevocationSnapshot
impl Clone for RevocationSnapshot
Source§fn clone(&self) -> RevocationSnapshot
fn clone(&self) -> RevocationSnapshot
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more