code wiki / _hdl_build / nx_mirror_orchestrator_gate.nx

nx_mirror_orchestrator_gate.nx

buildroot/runtime/_hdl_build/nx_mirror_orchestrator_gate.nx

8616 B127 linesdepth 6pulls 6 transitivereach 0 importersview sourcekind gate/prooftopic mirror
docsdependenciesstructsconstsfunctions

about

nx_mirror_orchestrator_gate.nx -- GATE for nx_mirror_orchestrator (rung-1: the deterministic, NEVER-BRICK core of "mirror a published open artifact -> NAS + receipt", composing the shipped sovereign primitives). Proves, with NO live network and NO NAS write: T1 SCHEME RESOLVE -- http/https->HTTP, torrent/magnet->TORRENT, unknown->REJECT (fail-closed transport). T2 BYTE-EXACT VERIFY-- sha256("abc") == the FIPS-180-4/NIST vector; mo_verify PASSES the true digest and FAILS a flipped one (never-store-corrupt: a byte-flipped/truncated/MITM'd file is rejected). T3 IDEMPOTENT KEY -- content-address key = sha|dest, deterministic (re-run identical) -> re-mirror = no-op. T4 RECEIPT SHAPE -- mo_receipt_bind emits EXACTLY status|sha|dest|verify|ts (the nx_pub_receipt binding rung-2 signs). T5 MANIFEST PARSE -- a TAB-delimited manifest row splits into name/scheme/source/sha/dest; missing field -> empty. T6 DRY PLAN / NEVER-BRICK -- an integrated dry plan (parse->resolve->verify->key->receipt) completes with ZERO live side effects, deterministically. Then prints the Apertus-shaped MIRROR PLAN (dry). GREEN iff T1-T6 pass. Sovereign nx_cc->nxasm (no gcc). expect_exit: 0 license_tier: ORIGINAL

dependencies 2 imports · 0 importers

nx_mirror_orchestrator.nx nx_syscalls.nx nx_mirror_orchestrator_gate.nx

imports: nx_mirror_orchestrator.nxnx_syscalls.nx

imported by: nobody (leaf or entry point)

call flow from main pre-order; caps 40 nodes / depth 6 declared; ↻ = already shown

main w sys_write mo_scheme_code mo_streq sys_mmap mo_sha_hex sys_mmap ↻ sha256_digest sys_mmap ↻ sha256_init sys_mmap ↻ sha256_k sha256_update sha256_compress_ni_blocks blk_set_byte sha256_compress sha256_compress_ni blk_word blk_byte sha256_final blk_set_byte ↻ sha256_compress ↻ mo_hexenc mo_streq ↻ mo_verify sys_mmap ↻ mo_sha_hex ↻ mo_streq ↻ wn w ↻ sys_mmap ↻ sys_write ↻ mo_cas_key mo_cat mo_cat ↻ mo_receipt_bind mo_cat ↻ build_row mo_cat ↻

structs

none

consts

none

functions

16func w(s: *u8) -> i64 { var n: i64=0; while s[n]!=(0 as u8){n=n+1} sys_write(1,s,n); return 0 }
called by 2: wnmain calls 1: sys_write
17func wn(v: i64) -> i64 { var m: i64=v; if m<0{w("-" as *u8);m=0-m} let t:*u8=sys_mmap(24); var k:i64=0; if m==0{t[0]=48 as u8;k=1} while m>0{t[k]=(48+(m%10)) as u8;m=m/10;k=k+1} var i:i64=0; let o:*u8=sys_mmap(24); while i<k{o[i]=t[k-1-i];i=i+1} sys_write(1,o,k); return 0 }
called by 1: main calls 3: wsys_mmapsys_write
20func build_row(out: *u8, a: *u8, b: *u8, c: *u8, d: *u8, e: *u8) -> i64
called by 1: main calls 1: mo_cat
28func main() -> i64