code wiki / _hdl_build / nx_attest_ceremony.nx
nx_attest_ceremony.nx
buildroot/runtime/_hdl_build/nx_attest_ceremony.nx
about
nx_attest_ceremony.nx -- the OPERATOR-SIDE key ceremony for the attestation plane, PROVEN against
the real verifier before any real key exists.
WHY: PROVEN=0/41 is bound on knowledge/attest_keys.conf (operator-held Ed25519 key). The recipe
existed only as PROSE derived from reading nx_evattest.nx -- and an untested recipe handed to the
operator is litter: if the claim-prefix boundary is off by one byte, every genuine attestation
reads BAD-SIGNATURE while all refusal paths still pass (nx_evattest.nx:136 warns exactly this).
This organ makes the ceremony EXECUTABLE and proves it byte-exact with a THROWAWAY key that is
never registered anywhere real -- the real key stays with the operator, never in an agent session.
THE LINE THIS TOOL DOES NOT CROSS: it contains no path that writes knowledge/attest_keys.conf.
Registration is the operator's act (the whole clause, per nx_evattest: "Minting a human
attestation is an act the operator performs with a key the operator holds"). This tool only makes
that act one command and PROVES the output verifies.
nx_attest_ceremony keygen <priv_out> -- 32B seed from /dev/urandom -> file; prints pub=<64hex>
(pub is PUBLIC; the priv file never prints)
nx_attest_ceremony sign <priv_file> <row_file> -- signs the row file's CLAIM PREFIX (trailing newline
stripped), prints the full signed row
nx_attest_ceremony -- GATE: 6 teeth against the REAL at_verify_row
license_tier: ORIGINAL layer: evidence module: nishi-core.evidence.attest_ceremony
dependencies 1 imports · 0 importers
imports: nx_evattest.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
| 23 | const K_MAGIC_8192: i64 = 8192 |
| 24 | const K_MAGIC_8000: i64 = 8000 |
| 25 | const K_MAGIC_65536: i64 = 65536 |
| 26 | const K_MAGIC_65000: i64 = 65000 |
| 27 | const K_MAGIC_4096: i64 = 4096 |
| 28 | const K_MAGIC_4000: i64 = 4000 |
functions
| 30 | func ac_p(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 1: main |
| 31 | func ac_slen(s: *u8) -> i64 { var n: i64=0; while s[n]!=(0 as u8){n=n+1} return n } called by 1: main |
| 32 | func ac_hex(b: *u8, n: i64, out: *u8) -> i64 |
| 46 | func ac_has(b: *u8, s: i64, e: i64, pat: *u8) -> i64 called by 1: main |
| 60 | func ac_n(v: i64) -> i64 |
| 71 | func ac_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 } |
| 75 | func ac_random32(out: *u8) -> i64 |
| 86 | func ac_sign_row(priv: *u8, row: *u8, rowlen: i64, out: *u8) -> i64 |
| 102 | func main(argc: i64, argv: *i64) -> i64 |