mirror of
https://github.com/gesellix/Bose-SoundTouch.git
synced 2026-08-19 00:56:16 +00:00
fix(web): URL Configuration verdict respects DNS interception
The URL Configuration cell flagged "Original (Bose cloud)" with a red ❌ even when the DNS hook (or /etc/hosts redirects, deprecated though it is) was actively intercepting those hostnames and routing them at AfterTouch — i.e. the expected migrated state for the DNS method. urlConfigVerdict now factors in resolv_migrated/hosts_migrated: - URL flip (xml or telnet) active → ✅ "AfterTouch URLs" - URL flip not active, DNS interception on → ✅ "Original (Bose cloud) — intercepted via DNS, device reaches AfterTouch" - URL flip not active, no DNS interception → ❌ "Original (Bose cloud) — not intercepted, device will reach the real Bose cloud" The third case is the only one that's actually broken; the first two are valid migrated states for different methods. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 4.7
parent
9160d803da
commit
d6e9639d89
@@ -2586,13 +2586,25 @@ function formatURLPair(xmlVal, telVal) {
|
||||
return `xml: ${xmlVal} • live: ${telVal}`;
|
||||
}
|
||||
|
||||
// urlConfigVerdict reports the URL-flip axis in the context of DNS
|
||||
// interception, because "URLs still point at Bose" is only a problem
|
||||
// if nothing else is redirecting them. When the DNS hook (or, less
|
||||
// preferably, /etc/hosts) is intercepting the Bose hostnames, leaving
|
||||
// the on-device URL config untouched is the *expected* migrated state
|
||||
// for that method — flagging it red would be misleading.
|
||||
function urlConfigVerdict(summary) {
|
||||
const xml = !!summary.xml_migrated;
|
||||
const tel = !!summary.telnet_migrated;
|
||||
if (!xml && !tel) return {icon: "❌", text: "Original (Bose cloud)", note: ""};
|
||||
if (xml && tel) return {icon: "✅", text: "Migrated to AfterTouch", note: "(XML + telnet runtime in sync)"};
|
||||
if (xml) return {icon: "✅", text: "Migrated to AfterTouch", note: "(XML only — telnet runtime may still hold the old URLs)"};
|
||||
return {icon: "✅", text: "Migrated to AfterTouch", note: "(telnet runtime — reboot to persist into the on-disk XML)"};
|
||||
const dns = !!summary.resolv_migrated || !!summary.hosts_migrated;
|
||||
|
||||
if (xml && tel) return {icon: "✅", text: "AfterTouch URLs", note: "(XML + telnet runtime in sync)"};
|
||||
if (xml) return {icon: "✅", text: "AfterTouch URLs", note: "(XML only — telnet runtime may still hold the old URLs)"};
|
||||
if (tel) return {icon: "✅", text: "AfterTouch URLs", note: "(telnet runtime — reboot to persist into the on-disk XML)"};
|
||||
|
||||
// Neither URL-flip mechanism is active. Whether that's OK depends
|
||||
// on whether DNS interception is doing the redirect.
|
||||
if (dns) return {icon: "✅", text: "Original (Bose cloud)", note: "— intercepted via DNS, device reaches AfterTouch"};
|
||||
return {icon: "❌", text: "Original (Bose cloud)", note: "— not intercepted, device will reach the real Bose cloud"};
|
||||
}
|
||||
|
||||
function dnsInterceptionVerdict(summary) {
|
||||
|
||||
Reference in New Issue
Block a user