Files
noahandClaude Opus 4.8 f9cd12b374
source / check (pull_request) Skipped
verify / verify (pull_request) Failing after 8m16s
verify / verify-windows (pull_request) Skipped
feat(gui): drop typed-FLASH step; raise report-relay rate limit
Issue #41: installing alkane OS and restoring to stock no longer require
typing FLASH. The dialog, the board list and the Install/Restore button are
the confirmation; the destructive-action warning stays visible. Removes the
now-unused confirm inputs from the install and uninstall dialogs.

Report relay: raise RATE_PER_IP 5 -> 100 and RATE_GLOBAL 60 -> 300 so bench
testing can file more reports without hitting the hourly cap. Applied live on
the Gitea host and recorded here.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01B1W6qKwKxq3oUPDKWicM6i
2026-11-13 10:18:36 -06:00
..

Report relay

Files the app's bug reports and feature requests as issues in blueflare/alkane-toolkit. The app's Bug report button posts the report here; the relay holds the only token, so the public app download carries no secret.

app --HTTPS--> gitea.bluefla.re/alkane-report/ (nginx) --> relay --> Gitea API

What it does

  • POST /v1/report takes the JSON the app sends (kind, text, version and OS context, optional log) and answers 201 {"number", "url"} or an error {"error": "..."} the app shows as is. GET /healthz answers 200.
  • Checks: type is bug, ui or feature; text 1 to 8,000 characters; each context value at most 120 printable characters; log at most 16 KiB; body at most 64 KiB (nginx enforces the same).
  • Rate limits, in memory: 5 reports per client IP per hour and 60 in all. Over the limit: 429 with Retry-After. At most 4 reports in flight. The client IP is X-Real-IP from nginx. Office LAN clients reach nginx through the router's hairpin NAT, so they share one IP and one limit.
  • Scrubs the log a second time (the app scrubs first): password, token, secret and similar values, Authorization/Cookie values, URL passwords and PEM private keys become [redacted].
  • @name in a report cannot notify anyone (a zero-width space follows @).
  • The issue title is the text's first line (up to 100 characters). The body has the type, a context table, the text, and the log in a collapsed block. Labels: the type (bug, ui, feature) and from-app.
  • Nothing is stored. Each report leaves one log line: the client IP and the outcome (filed #N, refused <status>, rate limited, tracker error), never the report's text.

Gitea account

Issues are filed as alkane-reporter, a local non-admin user with a random password that is never used. Its only access is the org team alkane-reporters (units repo.code: read, repo.issues: write) on alkane-toolkit. Its token alkane-toolkit-bug-reports has the scopes write:issue and read:repository. This mirrors FLARE's flare-reporter.

Deployment

On the Gitea host, recorded in the flare-deployment repository (runbooks/alkane-report-relay.md):

# in /opt/flare/deploy/alkane-report-relay, holding relay.py, Dockerfile, compose.yml
PROXY_NETWORK=flare_default docker compose -p alkane-report-relay up -d --build

The token file is secrets/gitea_token next to the compose file (directory 0700, never committed). nginx routes location /alkane-report/ in the gitea.bluefla.re server block to alkane-report-relay:8080.

Tests

python3 tools/report-relay/test_relay.py

They run the real HTTP handler against a fake Gitea: filing, scrubbing, mention handling, validation, size and rate limits, and tracker errors. CI runs them in the verify workflow's unit tests.