Expand description
kubo-compatible IPFS CID computation for Aleph Cloud.
This crate is the single source of truth for client-side content addressing in the Aleph Rust workspace:
cid: the string-validatedcid::Cidtype (CIDv0/CIDv1), with serde support behind theserdefeature.verify: streaming CID hashers (verify::Hasher) for IPFS CIDv0/CIDv1 (UnixFS dag-pb, 256 KiB chunks, raw leaves), plusverify::compute_cidfor one-shot CIDv0 computation.folder_hash: UnixFS directory DAG construction matchingipfs add -r(plain directories and HAMT shards), with a block sink for streaming the DAG into a CAR file.car: CARv1 framing: header/block writers and a strict root reader.
It deliberately contains no networking, signing, or async code, and no
Aleph message types, so that it can be reused as-is from FFI bindings
(e.g. a Python wheel). Golden CIDs in tests/folder_hash.rs are
regenerated against real kubo via tests/regen-folder-hash-goldens.sh.
Modules§
- car
- CARv1 framing for IPFS directory uploads.
- cid
- folder_
hash - Local UnixFS DAG construction for folder uploads.
- verify
Structs§
Enums§
Functions§
- collect_
folder_ files - Walks
rootand returns one entry per regular file, with the relative path normalized to forward-slash separators.