From 915fca496f03fe638867393de176c17b77097a4b Mon Sep 17 00:00:00 2001 From: Tobias Gesellchen Date: Fri, 22 May 2026 18:29:57 +0200 Subject: [PATCH] feat(export): improve diagnostic report web UI Add a
block listing what the encrypted archive contains so reporters know what they're sharing before clicking. After a successful download, show two submission options with email preferred: aftertouch-support@gesellix.net (mailto link with pre-filled subject and filename) or a GitHub issue with the file renamed to .txt (GitHub blocks .age uploads). Co-Authored-By: Claude Sonnet 4.6 --- pkg/service/handlers/web/index.html | 13 +++++++++++++ pkg/service/handlers/web/js/script.js | 11 ++++++++++- 2 files changed, 23 insertions(+), 1 deletion(-) diff --git a/pkg/service/handlers/web/index.html b/pkg/service/handlers/web/index.html index c7b09fc..d2bef36 100644 --- a/pkg/service/handlers/web/index.html +++ b/pkg/service/handlers/web/index.html @@ -1511,6 +1511,19 @@ findings that may need attention. Quick fixes are offered for issues the service knows how to remediate.

+
+ What does the diagnostic report contain? +
    +
  • Health check results and current device state
  • +
  • Device XML files from the datastore (no passwords)
  • +
  • HTTP response samples from speaker endpoints
  • +
  • System files: CA bundle, DNS resolver config
  • +
  • Speaker CA bundle and kernel log (via SSH, if reachable)
  • +
  • Service log tail
  • +
  • Settings file with secrets redacted
  • +
+

The archive is encrypted with the project maintainer's public key — only they can open it.

+
Loading…
diff --git a/pkg/service/handlers/web/js/script.js b/pkg/service/handlers/web/js/script.js index bcb2b32..bd5852b 100644 --- a/pkg/service/handlers/web/js/script.js +++ b/pkg/service/handlers/web/js/script.js @@ -4038,7 +4038,16 @@ async function downloadDiagnostic() { document.body.removeChild(a); URL.revokeObjectURL(url); - if (statusEl) statusEl.textContent = `Downloaded: ${filename}`; + if (statusEl) { + const safe = filename.replace(/&/g, "&").replace(//g, ">"); + statusEl.innerHTML = + `Downloaded: ${safe}
` + + `To share it, please prefer email: ` + + `aftertouch-support@gesellix.net. ` + + `Alternatively, open a GitHub issue ` + + `and attach the file renamed to ${safe}.txt ` + + `(GitHub blocks .age uploads; adding .txt works around that).`; + } } catch (e) { if (statusEl) statusEl.textContent = `Failed to download diagnostic: ${e.message || e}`; }