code wiki / _hdl_build / nx_pub_receipt_gate.nx

nx_pub_receipt_gate.nx

buildroot/runtime/_hdl_build/nx_pub_receipt_gate.nx

6714 B78 linesdepth 10pulls 17 transitivereach 0 importersview sourcekind gate/prooftopic pub
docsdependenciesstructsconstsfunctions

about

nx_pub_receipt_gate.nx -- referee for the SOVEREIGN-STORED publish receipt system (nx_pub_receipt on nx_seg_store + canon records, NO tsv). Proves the research-grounded breadth: ACK/NACK, DSN states, return-receipt query, dead- letter, idempotence, status transition (latest-wins in the additive store), no-false-published for an unknown artifact, provenance (the stored canon record carries the content sha), and non-repudiation (genuine receipt verifies; forged key + a tampered binding fail). -> knowledge/status/pub_receipt_gate.log.

dependencies 3 imports · 0 importers

nx_pub_receipt.nx nx_ed25519_signature.nx nx_syscalls.nx nx_pub_receipt_gate.nx

imports: nx_pub_receipt.nxnx_ed25519_signature.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 g_w sys_write sys_now_ms sys_mmap sys_clock_gettime_mono sys_mmap ↻ g_cat ed25519_pub_from_priv sys_mmap ↻ ed25519_sha512 sys_mmap ↻ sha512_init sha512_update sha512_blk_set_byte blk_get_i64 blk_set_i64 sha512_compress sys_mmap ↻ blk_get_i64 ↻ sha512_gamma0 rotr64_v shr64_v sha512_gamma1 rotr64_v ↻ shr64_v ↻ sha512_sigma1 rotr64_v ↻ sha512_ch sha512_k sha512_sigma0 rotr64_v ↻ sha512_maj sha512_final sha512_blk_set_byte ↻ sha512_compress ↻ ge_p3_alloc sys_mmap ↻ fe_alloc nx_scratch

structs

none

consts

none

functions

10func g_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 3: g_nchkmain calls 1: sys_write
11func g_n(v: i64) -> i64 { var m: i64=v; if m<0{g_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 2: chkmain calls 3: g_wsys_mmapsys_write
12func gw(fd: i64, s: *u8) -> i64 { var n: i64=0; while s[n]!=(0 as u8){n=n+1} sys_write(fd,s,n); return 0 }
called by 1: main calls 1: sys_write
13func g_cat(dst: *u8, off: i64, s: *u8) -> i64 { var o: i64=off; var i: i64=0; while s[i]!=(0 as u8){dst[o]=s[i];o=o+1;i=i+1} return o }
called by 1: main
14func chk(got: i64, want: i64, label: *u8) -> i64 { g_w(" "); g_w(label); g_w(" got="); g_n(got); g_w(" want="); g_n(want); if got==want { g_w(" PASS\n"); return 1 } g_w(" FAIL\n"); return 0 }
called by 1: main calls 2: g_wg_n
16func main() -> i64