nx_edge_repoint.nx
buildroot/runtime/nx_edge_repoint.nx
about
nx_edge_repoint.nx -- SOVEREIGN edge repoint: make the sovereign edge (sites.elf :8443) win WAN :443.
Fixes the D008 :443 co-squat by adding a PORT-TRANSLATING DNAT on the home GL.iNet: wan:443/tcp ->
192.168.8.227:8443, so WAN clients reach sites.elf directly instead of DSM's nginx (which 301->502s /search).
Drives the router over OUR OWN sovereign SSH (nx_ssh_lib); reads the router password by ABSOLUTE path so it
runs correctly from any tools-daemon CWD. Reversible by construction: `off` deletes the added redirect.
list -> show firewall redirects (inspect the current :443 path BEFORE changing anything)
on -> add nishimap443: wan:443/tcp -> 192.168.8.227:8443 DNAT; commit; reload
off -> delete nishimap443; commit; reload (revert to the prior WAN :443 path)
Map is HARDCODED (443->8443) so the tool cannot be repurposed. license_tier: ORIGINAL
dependencies 2 imports · 0 importers
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
structs
| none |
consts
| 12 | const ER_MAGIC_8192: i64 = 8192 |
| 14 | const ER_PW: *u8 = "/volume1/ai/torrent/data/router.pw" as *u8 |
| 15 | const ER_ROUTER: i64 = (192 << 24) | (168 << 16) | (8 << 8) | 1 // 192.168.8.1 (GL.iNet LAN) |
functions
| 17 | func er_app(dst: *u8, o: i64, s: *u8) -> i64 { 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: main |
| 18 | func er_streq(a: *u8, b: *u8) -> i64 { var i: i64=0; while a[i]!=(0 as u8) { if a[i]!=b[i] { return 0 } i=i+1 } if b[i]!=(0 as u8) { return 0 } return 1 } called by 1: main |
| 20 | func main(argc: i64, argv: *i64) -> i64 |