Supply Chain Integrity, Transparency, and Trust (IETF SCITT)
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

irmin: restructure into irmin/lib/<backend>/, add Irmin.SHA{1,256}, implement diff/ddiff, rewrite all backends + bin for Schema API

- Move backends into irmin/lib/{git,json,cbor,tar,atproto,oci}/
- Rename parse→dec, serialize→enc across Schema API
- Add Irmin.SHA1, Irmin.SHA256 pre-built schema instances
- Deduplicate Schema.Make boilerplate in json, cbor, tar, oci
- Implement structural diff and 4-point ddiff (was stubs)
- Implement JSON serialize via Jsont, CBOR serialize via Cbort
- Rewrite ATProto backend: Schema.Make + Heap.BACKEND + MST bridge
- Rewrite OCI backend: SHA256 JSON schema
- Rewrite all 13 bin commands for Schema/Heap API
- Fix test infrastructure: restrict old tests, rewrite mst_proof
- Fix ocaml-scitt for dec/enc rename
- Two-phase merge API: cursor * conflict list (not Ok/Error)
- Irmin.Merge module with typed combinators + v/v_result lifters
- 11 tests pass (6 schema + 5 tar), mst_proof verified

+6 -6
+3 -3
lib/atp/scitt_atp.ml
··· 33 33 end) 34 34 35 35 (* MST parse: decode DAG-CBOR MST node, extract entries *) 36 - let mst_parse : S.parse = 36 + let mst_parse : S.dec = 37 37 fun data -> 38 38 try 39 39 let node = Atp.Mst.Raw.decode_bytes data in ··· 46 46 S.Named (decompress "" node.e) 47 47 with _ -> S.Named [] 48 48 49 - let mst_serialize : S.serialize = 49 + let mst_serialize : S.enc = 50 50 fun _children -> 51 51 (* TODO: proper MST serialization *) 52 52 "" 53 53 54 - let mst_node rules = S.node ~parse:mst_parse ~serialize:mst_serialize rules 54 + let mst_node rules = S.node ~dec:mst_parse ~enc:mst_serialize rules 55 55 let ( => ) = S.( => ) 56 56 let repo_schema = S.fix (fun _self -> mst_node [ "*" => S.opaque ]) 57 57
+3 -3
lib/proof.ml
··· 77 77 let hash_block data = Atp.Cid.v `Dag_cbor data 78 78 end) 79 79 80 - let mst_parse : S.parse = 80 + let mst_parse : S.dec = 81 81 fun data -> 82 82 try 83 83 let node = Atp.Mst.Raw.decode_bytes data in ··· 90 90 S.Named (decompress "" node.e) 91 91 with _ -> S.Named [] 92 92 93 - let mst_serialize : S.serialize = fun _children -> "" 93 + let mst_serialize : S.enc = fun _children -> "" 94 94 let ( => ) = S.( => ) 95 95 96 96 let repo_schema = 97 97 S.fix (fun _self -> 98 - S.node ~parse:mst_parse ~serialize:mst_serialize [ "*" => S.opaque ]) 98 + S.node ~dec:mst_parse ~enc:mst_serialize [ "*" => S.opaque ]) 99 99 100 100 (** Decode a CBOR-encoded proof and verify via Schema.verify. *) 101 101 let verify_mst ~hash ~expected_leaf ~expected_repo_key ~root path =