vfa_tui/models/
integrity.rs1use serde::{Deserialize, Serialize};
2
3#[derive(Debug, Clone, Serialize, Deserialize)]
5#[serde(deny_unknown_fields)]
6pub struct AssetIntegrity {
7 pub manifest_version: u32,
8 pub algorithm: String,
9 pub scope: IntegrityScope,
10 pub trees: Vec<IntegrityTree>,
11 pub root_files: Vec<IntegrityFile>,
12 pub aggregate_sha256: String,
13}
14
15#[derive(Debug, Clone, Serialize, Deserialize)]
17#[serde(deny_unknown_fields)]
18pub struct IntegrityScope {
19 pub trees: Vec<String>,
20 pub root_files: Vec<String>,
21}
22
23#[derive(Debug, Clone, Serialize, Deserialize)]
25#[serde(deny_unknown_fields)]
26pub struct IntegrityTree {
27 pub tree: String,
28 pub aggregate_sha256: String,
29 pub files: Vec<IntegrityFile>,
30}
31
32#[derive(Debug, Clone, Serialize, Deserialize)]
34#[serde(deny_unknown_fields)]
35pub struct IntegrityFile {
36 pub path: String,
37 pub sha256: String,
38 pub bytes: u64,
39}