code wiki / _hdl_build / nx_aw_push.nx

nx_aw_push.nx

buildroot/runtime/_hdl_build/nx_aw_push.nx

8149 B145 linesdepth 10pulls 22 transitivereach 0 importersview sourcekind tooltopic aw
docsdependenciesstructsconstsfunctions

about

nx_aw_push.nx -- SOVEREIGN file push to the NAS (vault-backed, no /tmp staging, no shells). Gets the NAS password from the vault (nx_machine_key + nx_vault.elf), SSHes to 192.168.8.227 as elderwesto, and STREAMS a local file into a remote write-command via chunked SSH channel data (ssh_put_file from nx_ssh_putpage). payload = local file path read from /mnt/c/.../awpush.src (one line) dst-cmd = remote command read from /mnt/c/.../awpush.dst (e.g. "mkdir -p d; cat > d/f; chmod +x d/f") license_tier: ORIGINAL (vault spine from nx_aw_nasfix, stream spine from nx_ssh_putpage)

dependencies 2 imports · 0 importers

nx_syscalls.nx nx_ssh_lib.nx nx_aw_push.nx

imports: nx_syscalls.nxnx_ssh_lib.nx

imported by: nobody (leaf or entry point)

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

main sys_mmap p_run sys_fork sys_mmap ↻ sys_execve sys_exit sys_wait4 sys_read_file sys_openat_rd sys_lseek sys_mmap ↻ sys_read sys_close aw_napms sys_mmap ↻ p_unlink ssh_puts sys_write ssh_open_session sys_socket sys_mmap ↻ ssh_sockaddr nx_connect_bounded nx_fcntl sys_connect sys_mmap ↻ sys_poll ssh_kex sys_write ↻ sys_mmap ↻ ssh_read_line sys_read ↻ ssh_read_packet sys_mmap ↻ ssh_read_full sys_read ↻ ssh_u32be ssh_put_bytes ssh_put_byte

structs

none

consts

9const P_MAGIC_1000000: i64 = 1000000
10const P_MAGIC_65536: i64 = 65536
11const P_MAGIC_1048576: i64 = 1048576
12const P_MAGIC_16384: i64 = 16384
13const P_MAGIC_1024: i64 = 1024
15const P_SRC: *u8 = "/mnt/c/Users/elder/AppData/Local/Temp/awpush.src" as *u8
16const P_DST: *u8 = "/mnt/c/Users/elder/AppData/Local/Temp/awpush.dst" as *u8
17const P_SECRET_OUT: *u8 = "/tmp/nxsecret.out" as *u8
18const P_VAULT_NV: *u8 = "/home/elderwesto/.nishi/secrets/nas.nv" as *u8

functions

20func p_run(path: *u8, a1: *u8, a2: *u8) -> i64
39func aw_napms(ms: i64) -> i64 { let ts: *i64 = sys_mmap(16) as *i64; ts[0] = 0; ts[1] = ms * P_MAGIC_1000000; __syscall(35, ts as i64, 0, 0, 0, 0, 0); return 0 }
called by 1: main calls 1: sys_mmap
42func ssh_drain(st: *SshState) -> i64
50func ssh_put_file(st: *SshState, wcmd: *u8, wcmdlen: i64, data: *u8, datalen: i64) -> i64
90func main(argc: i64, argv: *i64) -> i64