pub struct VerifiedRevocationSnapshot<'g, 'r, 'a> { /* private fields */ }Expand description
Verified view for one grant and one accepted checkpoint. Construction is only possible after local receipt checks and the external completeness/freshness gate.
Implementations§
Source§impl<'g, 'r, 'a> VerifiedRevocationSnapshot<'g, 'r, 'a>
impl<'g, 'r, 'a> VerifiedRevocationSnapshot<'g, 'r, 'a>
pub fn verify( grant: &'g ConsentGrant, checkpoint: RevocationCheckpoint, receipts: &'r [RevocationReceipt], authority: &'a dyn RevocationCheckpointAuthority, clock: &mut dyn TrustedUnixClock, ) -> Result<Self, RevocationSnapshotError>
pub const fn grant_id(&self) -> [u8; 32]
pub const fn grant_digest(&self) -> [u8; 32]
pub const fn checkpoint(&self) -> RevocationCheckpoint
Trait Implementations§
Source§impl RevocationAuthority for VerifiedRevocationSnapshot<'_, '_, '_>
impl RevocationAuthority for VerifiedRevocationSnapshot<'_, '_, '_>
Source§fn is_revoked(
&self,
grant_id: &[u8; 32],
grant_digest: &[u8; 32],
current_time_unix: u64,
) -> Result<bool, AuthorizationError>
fn is_revoked( &self, grant_id: &[u8; 32], grant_digest: &[u8; 32], current_time_unix: u64, ) -> Result<bool, AuthorizationError>
Revalidate complete, restart-safe state for this exact grant digest at the
broker’s trusted current time. Implementations must recheck checkpoint
freshness/anti-rollback on every call; unknown state is an error, never false.
Auto Trait Implementations§
impl<'g, 'r, 'a> !RefUnwindSafe for VerifiedRevocationSnapshot<'g, 'r, 'a>
impl<'g, 'r, 'a> !Send for VerifiedRevocationSnapshot<'g, 'r, 'a>
impl<'g, 'r, 'a> !Sync for VerifiedRevocationSnapshot<'g, 'r, 'a>
impl<'g, 'r, 'a> !UnwindSafe for VerifiedRevocationSnapshot<'g, 'r, 'a>
impl<'g, 'r, 'a> Freeze for VerifiedRevocationSnapshot<'g, 'r, 'a>
impl<'g, 'r, 'a> Unpin for VerifiedRevocationSnapshot<'g, 'r, 'a>
impl<'g, 'r, 'a> UnsafeUnpin for VerifiedRevocationSnapshot<'g, 'r, 'a>
Blanket Implementations§
§impl<S, A> Aggregate<Result<S, Error>> for Awhere
A: Aggregate<S>,
impl<S, A> Aggregate<Result<S, Error>> for Awhere
A: Aggregate<S>,
Aggregate shares in an MPC protocol.
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more