code wiki / _hdl_build / nx_archive_live.nx

nx_archive_live.nx

buildroot/runtime/_hdl_build/nx_archive_live.nx

3951 B62 linesdepth 21pulls 151 transitivereach 0 importersview sourcekind tooltopic archive
docsdependenciesstructsconstsfunctions

about

nx_archive_live.nx -- the LIVE network front of the archive pipeline: fetch a real URL over sovereign TLS, run the extractor on the live page, ARCHIVE the real fetched bytes into a WARC, persist it, then reload + retrieve byte-exact -- proving the end-to-end "capture a live resource so it survives the origin vanishing" loop with real network. Run from nxc2 root (certdata + warc path relative). Default target = example.com (always-up, legal); pass any URL as argv[1]. license_tier: ORIGINAL

dependencies 8 imports · 0 importers

nx_syscalls.nx nx_x509_trust_store.nx nx_trust_store_load_from_certdata. nx_https_fetch_follow.nx nx_media_signal.nx nx_media_state.nx nx_media_extract.nx nx_web_archive.nx nx_archive_live.nx

imports: nx_syscalls.nxnx_x509_trust_store.nxnx_trust_store_load_from_certdata.nxnx_https_fetch_follow.nxnx_media_signal.nxnx_media_state.nxnx_media_extract.nxnx_web_archive.nx

imported by: nobody (leaf or entry point)

structs

none

consts

14const K_MAGIC_4194304: i64 = 4194304
15const K_MAGIC_8388608: i64 = 8388608
16const K_MAGIC_4096: i64 = 4096
17const K_MAGIC_65536: i64 = 65536

functions

19func pw(s: *u8) -> i64 { var n: i64=0; while s[n]!=(0 as u8){n=n+1} sys_write(1,s,n); return 0 }
called by 1: pn calls 1: sys_write
20func pn(v: i64) -> i64 { let b: *u8=sys_mmap(24); var m: i64=v; if m<0{pw("-" as *u8);m=0-m} let t: *u8=sys_mmap(24); var k: i64=0; if m==0{t[0]=48 as u8;k=1} while m>0{t[k]=(48+(m%10)) as u8;m=m/10;k=k+1} var i: i64=0; while i<k{b[i]=t[k-1-i];i=i+1} sys_write(1,b,k); return 0 }
21func psl(s: *u8) -> i64 { var n: i64=0; while s[n]!=(0 as u8){n=n+1} return n }
22func memeq(a: *u8, ao: i64, b: *u8, blen: i64) -> i64 { var i: i64=0; while i<blen { if (a[ao+i]&0xff)!=(b[i]&0xff) { return 0 } i=i+1 } return 1 }
24func main(argc: i64, argv: *i64) -> i64