Skip to main content

load

Function load 

Source
pub fn load(
    bytes: &[u8],
    trusted_root: ContentAddress,
) -> Result<Archive, LoadError>
Expand description

Load a .prx archive from its canonical bytes, FAIL-CLOSED against trusted_root: decode, re-derive the Merkle root, and admit the archive only if it matches. The trusted root comes from OUTSIDE the bytes (a peer’s claim, a lock pin) — that is what makes the check meaningful.