code wiki / _hdl_build / nx_aw_nasfix.nx

nx_aw_nasfix.nx

buildroot/runtime/_hdl_build/nx_aw_nasfix.nx

4973 B90 linesdepth 10pulls 22 transitivereach 0 importersview sourcekind tooltopic aw
docsdependenciesstructsconstsfunctions

about

nx_aw_nasfix.nx -- SOVEREIGN NAS diagnose+restore for the live sites daemon (andelinwest.com + nishifamily.com). No shells, no /tmp pre-staging: gets the NAS password straight from the sovereign vault (composes _offc/nx_machine_key.elf + _offc/nx_vault.elf, exactly as nx_secret_cli does), then SSHes to the NAS via the team's own nx_ssh_lib and runs the command read from a file (so diagnose vs restart is driven without rebuilding). ssh_exec streams remote stdout/stderr to fd 1. READ-ONLY unless the command file says otherwise. license_tier: ORIGINAL (spine reused from nx_aw_nasrecon)

dependencies 2 imports · 0 importers

nx_syscalls.nx nx_ssh_lib.nx nx_aw_nasfix.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 nf_run sys_fork sys_mmap nxa_die sys_write sys_exit nxa_lock_take nxa_lock_addr sys_write ↻ nxa_lock_give nxa_lock_addr ↻ nxa_report_overrun sys_write ↻ nxa_dump_printable sys_write ↻ nxa_dump_sizes sys_write ↻ sys_execve sys_exit ↻ sys_wait4 ssh_puts sys_write ↻ nf_unlink sys_mmap ↻ sys_read_file sys_openat_rd sys_lseek sys_mmap ↻ sys_read sys_munmap sys_close ssh_open_session sys_socket sys_mmap ↻ ssh_sockaddr nx_connect_bounded nx_fcntl sys_connect sys_mmap ↻

structs

none

consts

10const NF_CMD_PATH: *u8 = "/mnt/c/Users/elder/AppData/Local/Temp/nascmd.txt" as *u8
11const NF_SECRET_OUT: *u8 = "/tmp/nxsecret.out" as *u8
12const NF_VAULT_NV: *u8 = "/home/elderwesto/.nishi/secrets/nas.nv" as *u8

functions

14func nf_slen(s: *u8) -> i64 { var n: i64=0; while s[n]!=(0 as u8){n=n+1} return n }
17func nf_run(path: *u8, a1: *u8, a2: *u8) -> i64
37func main() -> i64