nx_orphan_reap_gate.nx
buildroot/runtime/nx_orphan_reap_gate.nx
about
nx_orphan_reap_gate.nx -- BITE-PROVEN guard test for nx_orphan_reap's victim-side protection.
WHY: nx_orphan_reap is destructive BY DESIGN. Its old guard screened the NEEDLE against a hand-typed
denylist, which can never be sound -- the dangerous case is a needle that matches a protected process
WITHOUT NAMING IT. Measured 2026-08-01: a reap aimed at :8447's owner would have killed the live
nx_translate_daemon; it survived ONLY because the guessed name missed. This gate proves the new
victim-side filter with BOTH polarities, because a protection cell that is green before the hazard
exists proves nothing.
THE TOOTH (gv_bite): a crafted PROTECTED sleeper must SURVIVE a reap aimed squarely at it (good==0),
and an otherwise-identical UNPROTECTED sleeper must DIE from the same needle (bad==1). One tooth,
both polarities -- a filter that spares everything would pass the first half and fail the second.
license_tier: ORIGINAL expect_exit:0
dependencies 3 imports · 0 importers
imports: nx_syscalls.nxnx_proc_ctl.nxnx_gate_verdict.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
| 18 | const OG_CAP: i64 = 8192 |
| 19 | const OG_SIGTERM: i64 = 15 |
| 20 | const OG_SETTLE_MS: i64 = 400 |
functions
| 23 | func og_spawn(elf: *u8, tag: *u8) -> i64 |
| 48 | func og_alive(pid: i64) -> i64 |
| 74 | func main(argc: i64, argv: *i64) -> i64 |