GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | ||||||||||||||||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | ||||||||||||||||
GeezerVison is showing github.com — proxy-relay: RELAY_TARGET_PORTS silently drops invalid entries and reinterprets non-literals — a typo'd target list starts a healthy relay with the wrong targets · Issue #1844 · developing-today/code Closed Labels app/proxy-relaybin/proxy-relay.mjs sandbox-to-laptop relayeffort/xsTrivial: expected under 30 minutes of workkind/bugSomething isn't working (prefixed form of the classic bug label)priority/normalOrdinary priority (the default)source/creatorFiled by the new-issue-creator jobtask/triageQueue packet kind: verify, reproduce, and route this itemuser/reviewNeeds a user-look: Muse reviews first and handles what it can Descriptionproxy-relay: RELAY_TARGET_PORTS silently drops invalid entries and reinterprets non-literals — a typo'd target list starts a healthy relay with the wrong targetsEvidence (verified this run, main
|
| input | result |
|---|---|
18745,19745 (control) |
[18745, 19745] |
18745,19745junk |
[18745] — typo'd target silently gone |
18745,99999 |
[18745] — out-of-range target silently gone |
18745,19745.9 |
[18745] — fractional target silently gone |
1e4 |
[10000] — scientific notation silently reinterpreted as a port |
0x4a39 |
[19001] — hex silently reinterpreted as a port |
18745,,19745 |
[18745, 19745] — empty segment silently gone |
No case throws, warns, or names the variable/value.
This relay is the sandbox's only path to the laptop fleet proxies, and its whole configuration surface is these env vars. A single typo in one target (19745junk, a transposed digit making 99999, a pasted hex/scientific value) does not fail the service — it degrades it silently: the relay reports healthy, the supervisor is satisfied, and connections to the missing target fail later, elsewhere, looking like a backend outage — the exact failure shape #483's strict parsing was built to eliminate for the other ports. Partial validity is the dangerous case; the all-invalid case already errors today.
RELAY_TARGET_PORTS is validated with the strict rule from bin/proxy-port.mjs (exactly an integer 1–65535, decimal digits only — e.g. via parseProxyPortValue per segment, or an equivalent strict helper): any invalid segment exits at startup naming RELAY_TARGET_PORTS and the offending value.18745,,19745, a trailing comma) get one pinned behaviour — refused at startup or explicitly documented as ignored — and a test pins whichever is chosen.bin/proxy-relay.test.mjs (or the parser's test file): the control list parses unchanged; each invalid class above (junk suffix, out of range, fractional, 1e4, 0x…) refuses; valid multi-target order is preserved (preferred-target order matters at :161)./health + forwarding paths are untouched.🤖 Agent note · filed
agent-note:v1 — picked up — OpenChamber scheduled lane
agent-note:v1 — done / handed off — OpenChamber scheduled lane
pr_opened; PR fix(proxy-relay): validate every RELAY_TARGET_PORTS entry #4034 is OPEN at commit f7ee7738b6be558a0b24f46829a91de8478c7a5d: fix(proxy-relay): validate every RELAY_TARGET_PORTS entry #4034node --test bin/proxy-port.test.mjs passed 14/14; syntax checks and git diff --check passed. Fresh PR state is OPEN/CLEAN; the only reported check is CodeRabbit skipped/NEUTRAL, with no CI jobs pending.user/review; removed the queue/in-progress/assigned labels. The queue task is complete; PR remains open for review.