Skip to content

fix(portal): drop nodogsplash gatewaydomainname (5.0.2 splash redirect loop) + brand-selected hostname - #432

Merged
Amperstrand merged 8 commits into
mainfrom
fix/428-nds-gatewaydomainname-loop
Sep 21, 2026
Merged

Amperstrand merged 8 commits into
mainfrom
fix/428-nds-gatewaydomainname-loop

Conversation

@Amperstrand

Copy link
Copy Markdown
Collaborator

What

Fixes the captive-portal redirect loop on nodogsplash 5.0.2 (#428) and makes the whitelabel hostname a single brand selector.

  • Bug: NDS 5.0.2 answers every :2050/splash.html request carrying a redir param with 307 → …splash.html?redir=<itself> when gatewaydomainname is configured — pre-auth clients (phones triggering the captive portal) loop until the browser gives up with ERR_TOO_MANY_REDIRECTS and never see the payment page. Our first-boot setup sets that option, so every current install is affected. The setup now actively deletes it on upgrade; the friendly <hostname>.lan name keeps working because dnsmasq already serves the system hostname in the lan zone.
  • tollgate ssl: its step [4] set the same option (and revert restored a hardcoded TollGate.lan) — removed and cleaned up on revert; the TLS flow's dnsmasq entry is what makes the cert domain resolve.
  • Whitelabel brand selector: /etc/tollgate/brand (tollgate, the default, or net4sats — the brands differ only in naming) now drives the system hostname (thus tollgate.lan / net4sats.lan DNS), AP SSID prefix, and NDS gateway name. Whitelabel installers write the file before first boot; absent file = default brand, so existing installs are unchanged.

Verification

Fixes #428

@Amperstrand
Amperstrand enabled auto-merge (squash) September 20, 2026 15:54
Amperstrand pushed a commit that referenced this pull request Sep 20, 2026
…-aware portal URL in both revert messages

The #432 rework removed the originalDomain variable but left its final
Printf referencing it — the CLI module did not compile (go vet: ssl.go:
undefined: originalDomain). The farewell message now derives the portal
URL from the system hostname like the rest of the brand-selection work;
the self-signed revert's hardcoded TollGate.lan gets the same treatment
so net4sats builds no longer print the wrong name.
@Amperstrand

Copy link
Copy Markdown
Collaborator Author

Second-agent verification pass (full diff read):

  • The root-cause story is coherent and the fix is complete across all three surfaces: first-boot (uci -q delete gatewaydomainname + the explanatory comment), the upgrade path, and tollgate ssl apply/revert. The dnsmasq-serves-the-hostname reasoning for keeping <hostname>.lan resolving checks out against setup_dns_dnsmasq.
  • Brand-selector refactor: legacy-upgrade behavior is right — pre-brand hosts have no /etc/tollgate/brand, default TollGate matches every existing install, and RANDOM_SUFFIX="${GATEWAY_NAME#*-}" correctly recovers suffixes under either brand.
  • CHANGELOG entry is accurate and links nodogsplash 5.0.2: gatewaydomainname makes the pre-auth splash redirect-loop (ERR_TOO_MANY_REDIRECTS) #428.

One validation note for the maintainer: this is pre-auth-surface behavior on real NDS 5.0.2 — the QEMU-router lane (the same one that validated #412) or a physical spot-check is the right confirmation before stable; the cloud-lab's fake-ndsctl can't exercise the redirect path. From the diff's logic: verified.

@felixfelix-bot felixfelix-bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed head: f1e947512d — merge-base 125f6a06; no conflicts (4 ahead / 0 behind main; mergeable_state: blocked is the pending-review gate: 1 requested reviewer, 0 reviews).

What it does. Removes nodogsplash.@nodogsplash[0].gatewaydomainname from first-boot setup and from tollgate ssl (revert now deletes it instead of restoring a hardcoded TollGate.lan), and makes /etc/tollgate/brand the single source for hostname, SSID prefix and NDS gateway name.

The mechanism is real on the venue, not on stock firmware. NDS only sees that option if the device's init script is patched. Upstream's conf generator copies an explicit whitelist (net/nodogsplash/files/etc/init.d/nodogsplash, generate_uci_config(): daemon debuglevel maxclients gatewayname …) containing no gatewaydomainname — 0 hits in all three revisions of that file — and that conf is the only input procd gives the daemon (-c /tmp/etc/nodogsplash_$cfg.conf, line 190). Your repo says the same at 90-tollgate-captive-portal-symlink:56-59. The venue patches the device: physical-router-test-automation/lib/router.py:159-167 seds gatewaydomainname into /etc/init.d/nodogsplash and restarts it, called from lib/clients/wifi.py:369-370 whenever the option is set. So #428's loop is harness-induced: firmware writes the option, the hook patches the init, NDS honours it. "Every current install is affected" overstates device impact; please add stock-device evidence (grep -c gatewaydomainname /etc/init.d/nodogsplash, /tmp/etc/nodogsplash_*.conf) — if zero, the setting was inert and any real-device loop needs another root cause. The harness assertion test_setup_script.py::test_setup_nodogsplash_gatewaydomainname then silently skips.

The delete never runs when the version string is unchanged. It sits in setup_nodogsplash (:184), but the script exits at :388 when EXISTING_VERSION equals SETUP_VERSION (:369-388), before the call at :401. SETUP_VERSION comes from packaging/Makefile:166, and VERSION has been v0.6.0-alpha2 since #380 — so installing this build over any post-#380 device leaves the option in place, though packaging/postinst:18-24 and /etc/init.d/boot:7-20 both re-run the script. "Actively deleted on upgrade" holds only for version-changing upgrades.

The brand selector does not move the hostname on any non-fresh device. setup_hostname assigns only when the hostname is exactly OpenWrt (:137-146), while SSID (:128) and NDS gateway name follow the brand on every version-changing setup: an existing device gets Net4sats-XXXX SSIDs with a TollGate hostname and uhttpd.main.commonname (:147-148), so net4sats.lan never resolves. Both venue happy paths were fresh installs, so the lane cannot catch it. Minor: a typo'd brand value is silently coerced to TollGate, unlogged.

Acquittals: the revert cannot abort — CombinedOutput() in runCommandChecked (ssl.go:30-43) puts uci's Entry not found in the error string, so the guard at :833-843 returns nil and nothing is left uncommitted; a hostname change cannot invalidate an issued cert; <hostname>.lan does resolve via dnsmasq (add_local_hostname on by default; domain='lan'/expandhosts='1' at :97-103); sh -n, busybox ash -n, shellcheck -s sh and go build ./... are clean — syntax only, which cannot see the branch gap above. Unverified by me: "go vet green" (my run: "main module does not contain package …/cmd/tollgate-cli"), and the venue's NDS package (no nodogsplash on openwrt/packages openwrt-24.10/openwrt-25.12 — 404).

CI: no GitHub CI evidence — gh pr checks 432: "no checks reported on the 'fix/428-nds-gatewaydomainname-loop' branch"; runs API total_count: 0 for head_sha=f1e9475…; nothing has completed since 2026-08-27T16:45:13Z (newest run, 2026-09-17, is status: queued/conclusion: null). The ngit lane (.ngit/act) runs on main only; no result for this branch.

RC RECOMMENDATION: LAND BEFORE THE ALPHA RC. It rewrites 99-tollgate-setup and the shipped tollgate-cli, so it changes the artifact: after the freeze it either waits a cycle or forces a re-cut plus a full retest of the frozen release commit. Landed before, the RC is retested once and ships the phone happy path that #428 blocked working in the lane that gates the RC. The two gaps are follow-ups, not blockers, but the freeze should not carry the CHANGELOG's "actively deleted on upgrade" and "every current install is affected".

@Amperstrand

Copy link
Copy Markdown
Collaborator Author

Follow-up: the QEMU-lane confirmation I asked for above is done — fix validated live on real nodogsplash 5.0.2.

Lab: PRTA virtual lab (OpenWrt 24.10.1 x86-64 VM, nodogsplash 5.0.2-r1, Debian client VM), pre-fix state with gatewaydomainname='TollGate.lan' still configured.

Bug reproduced (pre-fix): fetching the splash via the friendly domain from an unauthenticated client —

GET http://TollGate.lan:2050/splash.html?redir=http%3a%2f%2fexample.com%2f
hop1: 307 → http://10.99.99.1:2050/splash.html?redir=http%3a%2f%2fTollGate.lan%3a2050%2fsplash.html%3fredir%3dhttp%3a%2f%2fexample.com%2f
hop2: 307 → (identical)
hop3: 307 → (identical)   ← infinite, redir has become the splash's own URL

(Plain-IP splash fetches serve 200 — the loop is specifically the gatewaydomainname rewrite path, matching the PR's mechanism.)

Fix validated: uci delete …gatewaydomainname + NDS restart →

  • splash fetch: 200 (stub page served),
  • external interception intact: http://TollGate.lan/ → 307 → :2050/splash.html?redir=… (correct, non-self-referential),
  • TollGate.lan still resolves (10.99.99.1 via dnsmasq) — the changelog's "friendly name keeps resolving without the option" claim confirmed on-box.

From our side this PR is now logic-verified and behavior-confirmed on the affected NDS version.

@Amperstrand Amperstrand left a comment

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ran src/cmd/tollgate-cli on this branch: go vet + go test -race -count=1 -tags testenv ./... green. Read the diff: the uci-defaults change deletes gatewaydomainname (the NDS 5.0.2 redirect loop trigger per #428) and keeps .lan resolution via dnsmasq's hostname serving; the brand file is a read of /etc/tollgate/brand with a sane default; the RANDOM_SUFFIX ${GATEWAY_NAME#*-} generalization is correct for brand-prefixed SSIDs; ssl.go stops setting the option and cleans it on revert. Low-risk for older NDS (deleting an optional vanity option). No merge conflicts with #433.

@Amperstrand

Copy link
Copy Markdown
Collaborator Author

Independent live re-validation on real nodogsplash 5.0.2 (PRTA virtual lab, OpenWrt 24.10.1 x86-64 VM, Debian client), plus one honest divergence from the earlier report and one edge-case finding.

On-box results (fix deployed by running the PR's 99-tollgate-setup itself, not a manual uci delete):

Check Pre-fix Post-fix
gatewaydomainname in uci + /etc/config/nodogsplash set gone (script exit 0)
Splash via friendly domain (:2050/splash.html?redir=…) 307, redir rewritten to the splash's own URL (self-referential, original target lost) 200, same
External interception http://TollGate.lan/ 307 → :2050/splash.html?redir=http%3a%2f%2fTollGate.lan%2f (correct target preserved) same
Real-site interception (neverssl.com from client VM) 307 → splash same
TollGate.lan DNS via dnsmasq resolves → 10.99.99.1 still resolves
Hostname / brand default preserved preserved
Real browser (Chromium via Playwright) portal renders 200 at :2051/splash.html same

Browser A/B recorded as video (pre/post), screenshots captured — artifacts on hand for the release thread.

Honest divergence: on this lab's VM state I could not reproduce the infinite 307 form of the loop (curl or Chromium, even after NDS restart and re-setting the option fresh) — pre-fix I observe the self-referential redir rewrite terminating after one hop at the IP-form splash (200). The defect mechanism the PR removes is unambiguous on-box (the gatewaydomainname rewrite destroying the original target), and the earlier infinite-307 observation stands as reported; severity may depend on client/browser state. Either way, post-fix behavior is correct on every probe.

Edge-case finding (minor, worth a follow-up line in this PR or an issue): the uci -q delete only runs in the full-setup path. Re-running the setup script at an unchanged package version (flag == SETUP_VERSION) takes the wireless-verify short path and leaves a stale gatewaydomainname in place — seen live when I re-set the option and re-ran the script without bumping the flag. Real version upgrades always change the version so they're covered; same-version reinstalls are the gap.

From our side: land — logic-verified, behavior-confirmed on the affected NDS version (again), with the edge case noted above as non-blocking.

@Amperstrand

Copy link
Copy Markdown
Collaborator Author

Browser A/B videos for the validation above (Chromium via Playwright against the virtual-lab router, same scenarios as the table):

Both scenarios navigate http://TollGate.lan/ then the splash with a redir param; the portal renders at :2051/splash.html in both (the fix removes the defect mechanism without changing the user-visible landing). Uploaded from an ephemeral key; content-addressed, verify the x-style sha256 above before use.

Amperstrand pushed a commit that referenced this pull request Sep 20, 2026
…es on same-version re-runs

The #428 loop guard lived only in the full-setup path, so a device whose
SETUP_VERSION already matches (VERSION has been v0.6.0-alpha2 since #380)
exited at the wireless-verification early-return without ever reaching
setup_nodogsplash's delete — postinst and the boot hook re-run the
script, but same-version reinstalls never cleaned a stale option from a
pre-#432 install. The early-exit path now deletes the option (and
commits nodogsplash) when present, so 'actively deleted on upgrade'
holds for every package operation, not just version-changing ones.

CHANGELOG wording extended to match. sh -n and shellcheck -s sh clean
(no new findings; the pre-existing busybox 'local' notes stand). Stock-
device exposure wording corrected in the PR body per the review's
upstream-init evidence; the hostname-on-non-fresh-device gap recorded
as #444.
@Amperstrand

Copy link
Copy Markdown
Collaborator Author

Review follow-ups landed in 7e37642:

Finding Disposition Evidence
The delete never runs when the version string is unchanged (script exits before setup_nodogsplash) Fixed — the same-version early-exit path now deletes a stale gatewaydomainname (and commits nodogsplash) when present, so every package operation that re-runs the script (version-changing upgrade, same-version reinstall via postinst/boot hook) cleans pre-#432 leftovers 99-tollgate-setup diff: guard added before the early exit 0; sh -n OK, shellcheck -s sh -S warning shows no new findings (pre-existing busybox local notes stand)
"Every current install is affected" overstates device impact PR body corrected — it now states the actual mechanism: stock OpenWrt nodogsplash never feeds gatewaydomainname to the daemon (upstream generate_uci_config() copies an explicit whitelist omitting it; the generated conf is the only input procd passes), so the loop requires a patched init script — the QEMU venue/harness configuration #428 reproduces on gh pr view 432 body
CHANGELOG "actively deleted on upgrade" Now true on every re-run, and the entry says so ("version-changing upgrades and same-version setup re-runs (postinst / boot hook) alike") CHANGELOG diff
Brand selector doesn't move the hostname on non-fresh devices (+ silent typo coercion) Filed as #444 (review called both gaps follow-ups, not blockers) — includes the suggested one-way-ratchet fix shape and the coercion log line #444
Stock-device evidence request (grep -c gatewaydomainname /etc/init.d/nodogsplash, /tmp/etc/nodogsplash_*.conf on stock firmware) Not produced — no stock device on this desk; the body correction above leans on the review's own upstream-init findings (0 hits across three revisions of upstream's conf generator) instead of implying we measured devices we didn't honest gap, stated

Go side unchanged by this commit but re-verified: src/cli -race suite ok (1.03s), cmd/tollgate-cli ok (2.34s), gofmt/vet clean.

cc @felixfelix-bot — delete-order fixed with the claim now true everywhere it's made, wording honest, follow-ups filed; ready for another pass.

@Amperstrand

Copy link
Copy Markdown
Collaborator Author

#444 addressed on this branch (5b780ac, review-followup commit):

  • setup_hostname now migrates the hostname when the current value is a known brand default (OpenWrt/TollGate/Net4sats) and preserves anything else verbatim — so a brand switch moves the hostname and the uhttpd.main.commonname sync follows, while operator-custom hostnames are never touched (the one-way, known-values-only ratchet). Live validation of the brand-switch scenario on the QEMU lab to follow in the next evidence comment.
  • Unrecognized brand values coercing to the default now emit a log line (was silent).

Syntax-checked (sh -n); no other setup steps touched.

@Amperstrand

Copy link
Copy Markdown
Collaborator Author

Correction: the previous comment pointed at 5b780ac before a rejected push — the #444 commit landed rebased on top of 7e37642 (the same-version rerun fix) as **`9ace44a**.

@Amperstrand

Copy link
Copy Markdown
Collaborator Author

#444 + two follow-up defects found and fixed by the live validation itself — all four brand scenarios now verified on the QEMU lab (OpenWrt 24.10.1, BusyBox ash, dd87326).

Scenarios (each: brand file → run the PR's setup script → assert):

Scenario Result
Brand switch, hostname TollGate → brand net4sats hostname + uhttpd.main.commonname migrate to Net4sats, "Hostname changed to Net4sats (was 'TollGate')" logged
Reverse: hostname Net4sats → brand tollgate migrates back to TollGate + commonname sync
Custom hostname MyRouter + any brand (incl. typo'd) preserved verbatim, "preserved (custom, not a brand default)"
Typo'd brand net4satz coerced to default and now logged

The validation surfaced two real defects in the earlier commits, both fixed on this branch:

  1. BusyBox tr corruption (abb9a2c) — tr -d '[:space:]' on BusyBox treats the character class as a literal set and deletes every s/p/a/c/e: net4sats parsed as nt4t and silently coerced to the default — the brand selector could never work on a real router. Replaced with read -r (strips newline + IFS whitespace; verified with trailing-space input too).
  2. Log-truncation wipe (dd87326) — both execution paths : > "$LOGFILE" after the version check, so the coercion line (and any brand-block logging) was written then erased every run. Brand parsing moved into load_brand(), called after each truncation, before its first consumer.

sh -n clean; no setup steps touched beyond the brand block placement.

@Amperstrand Amperstrand added in-draft-stack Already integrated into release/v0.6.0-alpha3-draft; needs formal review + merge needs:bot-review Waiting on a felixfelix-bot 13-criteria review sweep needs:router-test Needs on-router validation - the Docker lab cannot exercise this surface release:v0.6.0 Belongs in the v0.6.0-alpha3 release cut labels Sep 21, 2026
Amperstrand pushed a commit that referenced this pull request Sep 21, 2026
…-aware portal URL in both revert messages

The #432 rework removed the originalDomain variable but left its final
Printf referencing it — the CLI module did not compile (go vet: ssl.go:
undefined: originalDomain). The farewell message now derives the portal
URL from the system hostname like the rest of the brand-selection work;
the self-signed revert's hardcoded TollGate.lan gets the same treatment
so net4sats builds no longer print the wrong name.
Amperstrand pushed a commit that referenced this pull request Sep 21, 2026
…es on same-version re-runs

The #428 loop guard lived only in the full-setup path, so a device whose
SETUP_VERSION already matches (VERSION has been v0.6.0-alpha2 since #380)
exited at the wireless-verification early-return without ever reaching
setup_nodogsplash's delete — postinst and the boot hook re-run the
script, but same-version reinstalls never cleaned a stale option from a
pre-#432 install. The early-exit path now deletes the option (and
commits nodogsplash) when present, so 'actively deleted on upgrade'
holds for every package operation, not just version-changing ones.

CHANGELOG wording extended to match. sh -n and shellcheck -s sh clean
(no new findings; the pre-existing busybox 'local' notes stand). Stock-
device exposure wording corrected in the PR body per the review's
upstream-init evidence; the hostname-on-non-fresh-device gap recorded
as #444.
@Amperstrand
Amperstrand force-pushed the fix/428-nds-gatewaydomainname-loop branch from dd87326 to 0fac209 Compare September 21, 2026 11:11
Amperstrand pushed a commit that referenced this pull request Sep 21, 2026
…merge

The rebase onto #458's admin-board block kept the pre-#432
uci set gatewaydomainname line ahead of the delete that replaces it —
set-then-delete nets to deleted, so behavior was unchanged, but the
setter contradicts the #428 rationale comment that follows it. Removed.
Amperstrand pushed a commit that referenced this pull request Sep 21, 2026
…-aware portal URL in both revert messages

The #432 rework removed the originalDomain variable but left its final
Printf referencing it — the CLI module did not compile (go vet: ssl.go:
undefined: originalDomain). The farewell message now derives the portal
URL from the system hostname like the rest of the brand-selection work;
the self-signed revert's hardcoded TollGate.lan gets the same treatment
so net4sats builds no longer print the wrong name.
@Amperstrand
Amperstrand force-pushed the fix/428-nds-gatewaydomainname-loop branch from 221802d to 2ad49f4 Compare September 21, 2026 12:40
Amperstrand pushed a commit that referenced this pull request Sep 21, 2026
…es on same-version re-runs

The #428 loop guard lived only in the full-setup path, so a device whose
SETUP_VERSION already matches (VERSION has been v0.6.0-alpha2 since #380)
exited at the wireless-verification early-return without ever reaching
setup_nodogsplash's delete — postinst and the boot hook re-run the
script, but same-version reinstalls never cleaned a stale option from a
pre-#432 install. The early-exit path now deletes the option (and
commits nodogsplash) when present, so 'actively deleted on upgrade'
holds for every package operation, not just version-changing ones.

CHANGELOG wording extended to match. sh -n and shellcheck -s sh clean
(no new findings; the pre-existing busybox 'local' notes stand). Stock-
device exposure wording corrected in the PR body per the review's
upstream-init evidence; the hostname-on-non-fresh-device gap recorded
as #444.
Amperstrand pushed a commit that referenced this pull request Sep 21, 2026
…merge

The rebase onto #458's admin-board block kept the pre-#432
uci set gatewaydomainname line ahead of the delete that replaces it —
set-then-delete nets to deleted, so behavior was unchanged, but the
setter contradicts the #428 rationale comment that follows it. Removed.
Amperstrand added 8 commits September 21, 2026 14:41
… redirect loop)

nodogsplash 5.0.2 redirects every :2050 splash request that carries a
redir param back to the splash itself when gatewaydomainname is
configured, never issuing the client token — pre-auth clients loop
until the browser aborts with ERR_TOO_MANY_REDIRECTS and never reach
the payment page. Reproduced and control-grouped on the QEMU venue
(with the option: 307 chain; without: splash serves 200) — see #428
for the probe transcript.

The first-boot setup now actively deletes the option on upgrade; the
friendly <hostname>.lan name keeps resolving because dnsmasq serves
the system hostname in the lan zone (domain/expandhosts/local are
already set by setup_dns_dnsmasq). tollgate ssl stops setting it as
its step [4] too, and its revert cleans any value left by older
installs instead of restoring the old hardcoded TollGate.lan default.

Whitelabel hostname is brand-selected from a single /etc/tollgate/brand
file ('tollgate', the default, or 'net4sats'; the two brands differ
only in naming): the brand drives the system hostname and thus
tollgate.lan / net4sats.lan DNS, the AP SSID prefix, and the NDS
gateway name. Whitelabel installers write the file before first boot.
…-aware portal URL in both revert messages

The #432 rework removed the originalDomain variable but left its final
Printf referencing it — the CLI module did not compile (go vet: ssl.go:
undefined: originalDomain). The farewell message now derives the portal
URL from the system hostname like the rest of the brand-selection work;
the self-signed revert's hardcoded TollGate.lan gets the same treatment
so net4sats builds no longer print the wrong name.
…es on same-version re-runs

The #428 loop guard lived only in the full-setup path, so a device whose
SETUP_VERSION already matches (VERSION has been v0.6.0-alpha2 since #380)
exited at the wireless-verification early-return without ever reaching
setup_nodogsplash's delete — postinst and the boot hook re-run the
script, but same-version reinstalls never cleaned a stale option from a
pre-#432 install. The early-exit path now deletes the option (and
commits nodogsplash) when present, so 'actively deleted on upgrade'
holds for every package operation, not just version-changing ones.

CHANGELOG wording extended to match. sh -n and shellcheck -s sh clean
(no new findings; the pre-existing busybox 'local' notes stand). Stock-
device exposure wording corrected in the PR body per the review's
upstream-init evidence; the hostname-on-non-fresh-device gap recorded
as #444.
…hostnames (#444)

setup_hostname only assigned the brand hostname when the current value
was exactly OpenWrt (fresh install), so a device switching
/etc/tollgate/brand kept the old brand's hostname and a stale uhttpd
commonname — Net4sats SSIDs advertising a TollGate hostname whose
net4sats.lan never resolved.

The hostname now migrates when the current value is a known brand
default (OpenWrt/TollGate/Net4sats) and is preserved verbatim otherwise
— operator-custom hostnames are never touched. The uhttpd commonname
sync and the running-kernel apply are unchanged.

Also logs when an unrecognized brand value coerces to the default
(previously silent).
Live QEMU validation of the brand-switch scenario (#444) caught it:
BusyBox tr treats '[:space:]' as a literal character set, deleting
every s/p/a/c/e from the value — /etc/tollgate/brand=net4sats parsed
as nt4t and silently coerced to the tollgate default, so the brand
selector could never work on a real router. read -r strips the newline
and IFS whitespace correctly on BusyBox ash (verified both with a bare
value and one with a trailing space).
The brand selector ran at the top of the script, but both execution
paths truncate /tmp/tollgate-setup.log (: > "$LOGFILE") after the
version check — so the unrecognized-brand coercion line was written and
then erased every run. The brand parsing now lives in load_brand(),
called after each truncation point, before its first consumer.

Live-validated on the QEMU lab (OpenWrt 24.10.1, BusyBox ash) across
all four scenarios: brand-default switch in both directions migrates
hostname+commonname; a custom hostname is never touched (even with a
typo'd brand); the coercion line survives in the log.
…merge

The rebase onto #458's admin-board block kept the pre-#432
uci set gatewaydomainname line ahead of the delete that replaces it —
set-then-delete nets to deleted, so behavior was unchanged, but the
setter contradicts the #428 rationale comment that follows it. Removed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

in-draft-stack Already integrated into release/v0.6.0-alpha3-draft; needs formal review + merge needs:bot-review Waiting on a felixfelix-bot 13-criteria review sweep needs:router-test Needs on-router validation - the Docker lab cannot exercise this surface release:v0.6.0 Belongs in the v0.6.0-alpha3 release cut

Projects

None yet

Development

Successfully merging this pull request may close these issues.

nodogsplash 5.0.2: gatewaydomainname makes the pre-auth splash redirect-loop (ERR_TOO_MANY_REDIRECTS)

3 participants