nx_content_put_gate.nx
buildroot/runtime/nx_content_put_gate.nx
about
nx_content_put_gate.nx -- THE GATE FOR THE CHUNKED UPLOAD DOOR: a real multi-MB payload round-trips
byte-identically, and every refusal the protocol promises actually fires.
Subject: the DEPLOYED nx_content_put binary (fork-style e2e; argv[1] overrides the subject path so
a bite can point at a staged mutant without touching live). Fixture: REAL corpus bytes -- five
concatenations of knowledge/rigcorpus/human.nxmesh (517,832 B each, durable since 2026-08-23), so
the sha teeth exercise real entropy, never zeros. Scratch lives in /tmp/nx_content_put_gate/ (the
gate-fixture law) and destinations use the organ's /tmp allowlist lane.
NOT ROSTER-ADMITTED: this gate forks the subject ~120 times and assembles megabytes -- a
multi-second subject (the voxchunk precedent); run it via nx_job_run, never on the 1.8s beat.
license_tier: ORIGINAL No hw writes (Rule 26). expect_exit: 0
dependencies 5 imports · 0 importers
imports: nx_syscalls.nxnx_gate_verdict.nxnx_base64.nxnx_sha256.nxnx_cdc_lib.nx
imported by: nobody (leaf or entry point)
call flow from main pre-order; caps 40 nodes / depth 6 declared; ↻ = already shown
structs
| none |
consts
| 20 | const G_SUBJECT_DEFAULT: *u8 = "./nx_content_put.elf" as *u8 |
| 21 | const G_CORPUS: *u8 = "knowledge/rigcorpus/human.nxmesh" as *u8 |
| 22 | const G_NCOPIES: i64 = 5 |
| 24 | const G_MULTI_MB: i64 = 2097152 |
| 25 | const G_SCRATCH: *u8 = "/tmp/nx_content_put_gate" as *u8 |
| 26 | const G_OUT: *u8 = "/tmp/nx_content_put_gate/out.txt" as *u8 |
| 27 | const G_DEST1: *u8 = "/tmp/nx_content_put_gate/dest1.bin" as *u8 |
| 28 | const G_DEST2: *u8 = "/tmp/nx_content_put_gate/dest2.bin" as *u8 |
| 29 | const G_DEST3: *u8 = "/tmp/nx_content_put_gate/dest3.bin" as *u8 |
| 30 | const G_DEST4: *u8 = "/tmp/nx_content_put_gate/dest4.bin" as *u8 |
| 31 | const G_DEST5: *u8 = "/tmp/nx_content_put_gate/dest5.bin" as *u8 |
| 32 | const G_SHAHEX: i64 = 64 |
| 33 | const G_DIGEST: i64 = 32 |
| 34 | const G_PATHCAP: i64 = 512 |
functions
| 36 | func g_slen(s: *u8) -> i64 { var n: i64 = 0; while s[n] != (0 as u8) { n = n + 1 } return n } |
| 37 | func g_mkdir(path: *u8) -> i64 |
| 44 | func g_exists(path: *u8) -> i64 { let fd: i64 = sys_openat_rd(path); if fd < 0 { return 0 } sys_close(fd); return 1 } |
| 45 | func g_itoa(v: i64, out: *u8) -> i64 |
| 59 | func g_find(hay: *u8, n: i64, needle: *u8) -> i64 |
| 72 | func g_num_after(hay: *u8, n: i64, key: *u8) -> i64 |
| 87 | func g_hex_into(d: *u8, out: *u8) -> i64 called by 1: main |
| 101 | func g_run(subject: *u8, a1: *u8, a2: *u8, a3: *u8, a4: *u8, a5: *u8, nargs: i64) -> i64 |
| 124 | func g_read_out(lp: *i64) -> *u8 |
| 130 | func main(argc: i64, argv: *i64) -> i64 |