pub struct RunEvidence {Show 13 fields
pub schema: String,
pub tsafe_attest_version: String,
pub started_at: DateTime<Utc>,
pub finished_at: DateTime<Utc>,
pub repo_path: String,
pub repo_commit: Option<String>,
pub command: Vec<String>,
pub contract: ContractRef,
pub environment: EnvironmentEvidence,
pub process: ProcessEvidence,
pub machine: MachineEvidence,
pub result: EnforcementResult,
pub signature: Option<SignaturePayload>,
}Expand description
Typed-evidence artifact for a single attested command execution.
RunEvidence is the post-run truth record: every field is observed
after the child process exits. It carries:
- Identity of the run (schema, version, timestamps, repo, command)
- A pointer to the contract the run was enforced against (
contract) - The parent-vs-child env diff with per-var BLAKE3 hashes
(
environment) - Process lifecycle observations (
process) - Host fingerprint (hashed only) (
machine) - Enforcement verdict (
result)
Construction is the caller’s responsibility — this module owns the type definition and validation only.
Fields§
§schema: String§tsafe_attest_version: StringProducing tool version (BLAKE3-converged tsafe-attest since v1.2.0).
Legacy algol_version field name is accepted on parse via
serde(alias) for the v1.x compat window; new emissions use
tsafe_attest_version.
started_at: DateTime<Utc>§finished_at: DateTime<Utc>§repo_path: String§repo_commit: Option<String>§command: Vec<String>§contract: ContractRef§environment: EnvironmentEvidence§process: ProcessEvidence§machine: MachineEvidence§result: EnforcementResult§signature: Option<SignaturePayload>Optional Ed25519 signature over the canonical form of every
other field on this artifact (Phase 5; see crate::sign).
None on legacy / unsigned emissions; Some(..) when the
producer had a signing key available and the operator did not
opt out via --no-sign. Skipped from the wire form when absent
so existing readers parse old artifacts unchanged.
Implementations§
Source§impl RunEvidence
impl RunEvidence
Sourcepub fn validation_errors(&self) -> Vec<String>
pub fn validation_errors(&self) -> Vec<String>
Return all validation errors for this artifact.
Empty vector indicates the artifact is structurally and
semantically valid. Used by Self::ensure_valid.
During the v1.x compat window, both tsafe.run.v1 and
algol.run.v1 are accepted for the schema field, and any hash
field accepts either blake3: (canonical) or sha256: (legacy)
prefixes.
Sourcepub fn ensure_valid(&self) -> Result<(), String>
pub fn ensure_valid(&self) -> Result<(), String>
Convert the validation-error list into a Result.
Trait Implementations§
Source§impl Clone for RunEvidence
impl Clone for RunEvidence
Source§fn clone(&self) -> RunEvidence
fn clone(&self) -> RunEvidence
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for RunEvidence
impl Debug for RunEvidence
Source§impl<'de> Deserialize<'de> for RunEvidence
impl<'de> Deserialize<'de> for RunEvidence
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
impl Eq for RunEvidence
Source§impl PartialEq for RunEvidence
impl PartialEq for RunEvidence
Source§fn eq(&self, other: &RunEvidence) -> bool
fn eq(&self, other: &RunEvidence) -> bool
self and other values to be equal, and is used by ==.Source§impl Serialize for RunEvidence
impl Serialize for RunEvidence
impl StructuralPartialEq for RunEvidence
Auto Trait Implementations§
impl Freeze for RunEvidence
impl RefUnwindSafe for RunEvidence
impl Send for RunEvidence
impl Sync for RunEvidence
impl Unpin for RunEvidence
impl UnsafeUnpin for RunEvidence
impl UnwindSafe for RunEvidence
Blanket Implementations§
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.