Skip to main content

AuditRecord

Struct AuditRecord 

Source
#[non_exhaustive]
pub struct AuditRecord {
Show 24 fields pub at: u64, pub level: AuditLevel, pub actor: String, pub action: AuditAction, pub object: String, pub outcome: AuditOutcome, pub grant: Option<GrantSummary>, pub role: Option<RoleChange>, pub violations: Vec<String>, pub suggestions: Vec<Suggestion>, pub decision: Option<DecisionSummary>, pub pending: Option<PendingRef>, pub recert: Option<RecertRef>, pub full_grant: Option<Grant>, pub resource: Option<Resource>, pub explanation: Option<Box<Explanation>>, pub tuple: Option<Tuple>, pub actor_detail: Option<Subject>, pub meta: Attributes, pub impact: Option<ImpactSummary>, pub before_digest: Option<String>, pub after_digest: Option<String>, pub prev_hash: Option<String>, pub hash: Option<String>,
}
Expand description

One record of the trail. The optional fields appear depending on the level.

Fields (Non-exhaustive)§

This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.
§at: u64

Milliseconds since the Unix epoch.

§level: AuditLevel§actor: String

Actor id, or its kind when anonymous.

§action: AuditAction§object: String

Grant id, the tuple’s object#relation@subject, or role@subject for a role change, with the scope after the role when there is one (role#scope@subject).

§outcome: AuditOutcome§grant: Option<GrantSummary>§role: Option<RoleChange>§violations: Vec<String>

Names of the invariants (standard) or name: message (detailed and above).

§suggestions: Vec<Suggestion>

Compensating changes the refusing invariants proposed (see Violation::suggestion), from standard upward: the subject id and the role, nothing else. Nothing was applied.

§decision: Option<DecisionSummary>§pending: Option<PendingRef>

The request of an approval-flow record, from standard upward.

§recert: Option<RecertRef>

The campaign of a recertification record, from standard upward.

§full_grant: Option<Grant>§resource: Option<Resource>

Full resource of a decision, from detailed upward. With actor_detail, it is enough to re-evaluate the decision against another policy.

§explanation: Option<Box<Explanation>>

Full trace of the decision, at forensic.

§tuple: Option<Tuple>§actor_detail: Option<Subject>§meta: Attributes§impact: Option<ImpactSummary>

What the change does to access (counts and a few examples), from detailed upward, on a change recorded with Governance::apply_with_impact.

§before_digest: Option<String>

Digest of the grant set before the change. For a role change, the digest of the subject’s roles.

§after_digest: Option<String>

Digest of the grant set after the change (equal to the previous one on a refusal). For a role change, the digest of the subject’s roles.

§prev_hash: Option<String>§hash: Option<String>

Trait Implementations§

Source§

impl Clone for AuditRecord

Source§

fn clone(&self) -> Self

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

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

Performs copy-assignment from source. Read more
Source§

impl Debug for AuditRecord

Source§

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

Formats the value using the given formatter. Read more
Source§

impl<'de> Deserialize<'de> for AuditRecord

Source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
Source§

impl PartialEq for AuditRecord

Source§

fn eq(&self, other: &Self) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more
Source§

impl Serialize for AuditRecord

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
Source§

impl StructuralPartialEq for AuditRecord

Auto Trait Implementations§

§

impl Forget for AuditRecord

§

impl Freeze for AuditRecord

§

impl Move for AuditRecord

§

impl RefUnwindSafe for AuditRecord

§

impl Send for AuditRecord
where RawVecInner: Send, BoxRaw<Condition>: Send, NodeRef<Owned, String, Value, LeafOrInternal>: Send, BoxRaw<(String, Value)>: Send, BoxRaw<Explanation>: Send,

§

impl Sync for AuditRecord
where RawVecInner: Sync, BoxRaw<Condition>: Sync, NodeRef<Owned, String, Value, LeafOrInternal>: Sync, BoxRaw<(String, Value)>: Sync, BoxRaw<Explanation>: Sync,

§

impl Unpin for AuditRecord
where *const u8 is !null: Unpin, Box<Condition>: Unpin, *const LeafNode<String, Value> is !null: Unpin, Box<(String, Value)>: Unpin, Box<Explanation>: Unpin,

§

impl UnsafeUnpin for AuditRecord

§

impl UnwindSafe for AuditRecord

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> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,

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 = !

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

fn try_from(value: U) -> Result<T, !>

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.