code wiki / (root) / nx_ltv_gate.nx

nx_ltv_gate.nx

buildroot/runtime/nx_ltv_gate.nx

5800 B124 linesdepth 8pulls 13 transitivereach 0 importersview sourcekind gate/proof
docsdependenciesstructsconstsfunctions

about

nx_ltv_gate.nx -- INDEPENDENT GATE: PAdES levels + the three-valued verdict (crown teeth). Proves the two things that decide whether an old signature survives: (1) an expired-certificate signature is INDETERMINATE, NEVER INVALID -- opposite legal outcomes, and calling it invalid impeaches a validly-signed document; (2) B-LT and up still verify PAST expiry because the revocation proof travels inside the file, whereas a chain WITHOUT revocation data is only B-T (the half-measure that looks archival and is not). WRITE BUDGET (debt 1785519597): reg_put is disk-bound at ~0.7s+ under NAS I/O contention; reg_get is ~70us. One signature, upgraded one component at a time, FIVE writes, unlimited free assertions. license_tier: ORIGINAL No hw writes (Rule 26). expect_exit: 0

dependencies 1 imports · 0 importers

nx_ltv_lib.nx nx_ltv_gate.nx

imports: nx_ltv_lib.nx

imported by: nobody (leaf or entry point)

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

main sys_now_us sys_mmap sys_clock_gettime_mono zz_pfx mt_catcopy mt_catn zz_puts zz_ck zz_puts ↻ zz_putn ltv_level ltv_level_pure ltv_is1 ltv_yes ltv_get ltv_key mt_catcopy ↻ reg_get reg_key reg_cat ss_get sys_mmap ↻ ss_scan mt_field mt_r32 mt_streq ltv_verify_at ltv_verify_pure ltv_is1 ↻ ltv_level ↻ ltv_yes ↻ ltv_self_contained ltv_self_contained_pure ltv_level ↻ ltv_set ltv_key ↻ canon_encode sys_mmap ↻ cc_cmp

structs

none

consts

none

functions

14func zz_puts(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: zz_ckzz_cksmain
15func zz_putn(v: i64) -> i64
called by 2: zz_ckmain
29func zz_ck(cnt: *i64, name: *u8, got: i64, want: i64) -> i64
called by 1: main calls 2: zz_putszz_putn
40func zz_cks(cnt: *i64, name: *u8, got: *u8, want: *u8) -> i64
called by 1: main calls 1: zz_puts
51func zz_pfx(tag: *u8, nonce: i64, out: *u8) -> i64
called by 1: main calls 2: mt_catcopymt_catn
62func main(argc: i64, argv: *i64) -> i64