nx_tracker.nx
buildroot/runtime/nx_tracker.nx
about
nx_tracker.nx -- BitTorrent HTTP tracker announce (bits-up), reuses the net
primitives.
module: nishi-core.torrent.tracker
depends: nx_str.nx, nx_syscalls.nx, nx_bencode.nx
capability: CORE_COMPUTE
wired_status: FULLY_WIRED
Build the announce request (%-encoded info_hash + peer_id + numeric params,
BEP-3) and parse the compact peer list (BEP-23: peers = 6N bytes, 4 IP + 2
port BE). The LIVE announce reuses nx_http_get_ua (the crawler's UA HTTP GET)
+ nx_net_governor (ISP-safe pacing) + DNS/TLS -- the reusability payoff: the
torrent client's tracker step IS the search engine's net stack. Pure builder
+ parser here (KAT'd); the socket round-trip is the shared primitive.
dependencies 3 imports · 1 importers
imports: nx_str.nxnx_syscalls.nxnx_bencode.nx
imported by: nx_tracker_test.nx
structs
| none |
consts
| none |
functions
| 20 | func _trk_hex(nib: i64) -> i64 called by 1: nx_trk_pct_encode |
| 25 | func _trk_unreserved(c: i64) -> i64 called by 1: nx_trk_pct_encode |
| 36 | func nx_trk_pct_encode(bytes: *u8, n: i64, out: *u8) -> i64 |
| 51 | func _trk_lit(out: *u8, o: i64, s: *u8) -> i64 |
| 56 | func _trk_dec(out: *u8, o: i64, v: i64) -> i64 |
| 67 | func nx_tracker_build_path(announce_path: *u8, aplen: i64, |
| 88 | func nx_tracker_parse_peers(resp: *u8, n: i64, out_ips: *i64, out_ports: *i64, max: i64) -> i64 |