nx_connect_e2e_client.nx
buildroot/runtime/nx_connect_e2e_client.nx
about
nx_connect_e2e_client.nx -- the FULL-E2E CONNECT client: key AGREEMENT + sealed send + decrypting
inbox, all client-side, all sovereign crypto compiled to WASM. This is the page that escapes the
zero-JS security ceiling AND closes the two rungs the 2026-07-23 honest grade left open:
(a) the conversation key is no longer typed -- it is AGREED via X25519 (RFC 7748; the shipped wasm
is KAT-proven in nx_wasm_vm: nx_x25519_wasm_vm_gate + nx_connect_keyx_vm_gate 5/5 DH agreement);
(b) the recipient has a DECRYPT view -- the inbox fetches ciphertext routed by the server's shared
content-blind plane and decrypts it in the browser with the same agreed key.
The cipher is sovereign ChaCha20 (nx_media_crypt_wasm; RFC 8439 bit-exact in-VM, gate 3/3). The JS is
the ACCEPTED minimum last-mile: instantiate wasm + marshal bytes + DOM. ALL crypto is in the wasm.
HONEST SCOPE (stated on the page too): the name->pubkey directory is first-come/latest-wins with NO
identity binding yet (classic TOFU gap; OPAQUE-bound identities = the next rung), and private keys
live in this browser's localStorage (per-name, so one browser can demo both ends).
nx_connect_e2e_client <chacha.wasm> <x25519.wasm> <out.html>
ce_emit_html(b64c, b64clen, b64x, b64xlen, dst) is the pure emitter (gate-testable without real wasm).
license_tier: ORIGINAL
dependencies 2 imports · 1 importers
imports: nx_syscalls.nxnx_base64.nx
imported by: nx_connect_e2e_client_gate.nx
call flow from main pre-order; caps 40 nodes / depth 6 declared; ↻ = already shown
structs
| none |
consts
| 19 | const K_MAGIC_524288: i64 = 524288 |
functions
| 21 | func ce_puts(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: ce_emit_html |
| 22 | func ce_putb(dst: *u8, off: i64, b: *u8, n: i64) -> i64 { var i: i64=0; while i<n { dst[off+i]=b[i]; i=i+1 } return off+n } called by 1: ce_emit_html |
| 25 | func ce_emit_html(b64c: *u8, b64clen: i64, b64x: *u8, b64xlen: i64, dst: *u8) -> i64 |
| 63 | func main(argc: i64, argv: *i64) -> i64 |