code wiki / _hdl_build / nx_aw_send.nx

nx_aw_send.nx

buildroot/runtime/_hdl_build/nx_aw_send.nx

12801 B226 linesdepth 10pulls 26 transitivereach 0 importersview sourcekind tooltopic aw
docsdependenciesstructsconstsfunctions

about

nx_aw_send.nx -- the SOVEREIGN file sender (operator: "nishi ecosystem from the hardware rung up, each rung; build if we are missing capabilities"). The MISSING rung was a coreutils-free transport receive: nx_aw_push/nx_put stream bytes over our own SSH but land them with a remote `cat > file.tmp && mv` shell. This organ closes that rung -- it streams a LOCAL file over the team's sovereign SSH straight into the NAS control-plane binary's receiver: `nx_hostctl recv <dest>` (see nx_hostctl cmd_recv). NO cat/mv/tee/dd, NO nascmd/.src/.dst spec files -- everything is argv-driven and the remote payload is ONE sovereign Nishi binary that atomically installs the bytes. Vault+SSH spine reused from nx_aw_push; the cat receive removed. nx_aw_send <local-src-path> <remote-dest-path> e.g. nx_aw_send _offc/nx_sites_daemon_v2.elf /volume1/homes/elderwesto/nishihost/sites.elf.new license_tier: ORIGINAL

dependencies 4 imports · 0 importers

nx_syscalls.nx nx_ssh_lib.nx nx_arbiter.nx nx_receipt.nx nx_aw_send.nx

imports: nx_syscalls.nxnx_ssh_lib.nxnx_arbiter.nxnx_receipt.nx

imported by: nobody (leaf or entry point)

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

main ssh_puts sys_write as_run sys_fork sys_mmap sys_execve sys_exit sys_wait4 sys_mmap ↻ fl_acquire fl_try fl_mkdir sys_mmap ↻ fl_path sys_openat_wr sys_flock sys_close fl_nap sys_mmap ↻ sys_read_file sys_openat_rd sys_lseek sys_mmap ↻ sys_read sys_close ↻ as_napms sys_mmap ↻ as_unlink as_slen ssh_open_session sys_socket sys_mmap ↻ ssh_sockaddr nx_connect_bounded nx_fcntl sys_connect sys_mmap ↻ sys_poll ssh_kex

structs

none

consts

15const AS_MAGIC_1000000: i64 = 1000000
16const AS_MAGIC_65536: i64 = 65536
17const AS_MAGIC_1048576: i64 = 1048576
18const AS_MAGIC_16384: i64 = 16384
19const AS_MAGIC_1024: i64 = 1024
20const AS_MAGIC_60000: i64 = 60000
21const AS_MAGIC_1800: i64 = 1800
23const AS_SECRET_OUT: *u8 = "/tmp/nxsecret.out" as *u8
24const AS_VAULT_NV: *u8 = "/home/elderwesto/.nishi/secrets/nas.nv" as *u8
25const AS_HOSTCTL: *u8 = "/volume1/homes/elderwesto/nishihost/nx_hostctl" as *u8

functions

27func as_slen(s: *u8) -> i64 { var n: i64=0; while s[n]!=(0 as u8){n=n+1} return n }
called by 1: main
28func as_run(path: *u8, a1: *u8, a2: *u8) -> i64
47func as_napms(ms: i64) -> i64 { let ts: *i64 = sys_mmap(16) as *i64; ts[0] = 0; ts[1] = ms * AS_MAGIC_1000000; __syscall(35, ts as i64, 0, 0, 0, 0, 0); return 0 }
called by 1: main calls 1: sys_mmap
50func ssh_drain(st: *SshState) -> i64
60func ssh_send_to(st: *SshState, wcmd: *u8, wcmdlen: i64, data: *u8, datalen: i64) -> i64
126func main(argc: i64, argv: *i64) -> i64