Skip to content

feat: send a User-Agent on relay WebSocket upgrades - #9246

Open
wpfleger96 wants to merge 1 commit into
mainfrom
hayt/relay-client-user-agent
Open

wpfleger96 wants to merge 1 commit into
mainfrom
hayt/relay-client-user-agent

Conversation

@wpfleger96

Copy link
Copy Markdown
Member

Relay WebSocket clients in this repo now send a User-Agent of the form <name>/<version> on the upgrade request. The version comes from the build.

Client User-Agent
buzz-acp buzz-acp/<crate version>
buzz-cli buzz-cli/<crate version>
buzz-ws-client (default) buzz-ws-client/<crate version>
buzz-pairing-cli buzz-pairing-cli/<crate version>
buzz-audio-client (default) buzz-audio-client/<crate version>
mobile (relay and huddle sockets) Buzz-Mobile/<app version>
  • buzz-ws-client: every connect path sends the default. A User-Agent in the caller's connect_with_headers headers replaces it, so other consumers can identify themselves without any new API. buzz-cli uses this to send its own name.
  • buzz-audio-client: keeps a User-Agent already on the host-supplied request, and adds its default otherwise.
  • Mobile: openRelayWebSocket sets the HTTP client's userAgent, which also covers the huddle transport. Startup fills in the app version from package_info_plus. Until that resolves, the value is Buzz-Mobile.

Each client has a test asserting the header on the upgrade request.

buzz-acp, buzz-cli, buzz-ws-client, buzz-pairing-cli, buzz-audio-client
and the mobile app now name themselves and their version on every relay
WebSocket upgrade. buzz-ws-client and buzz-audio-client default to their
own name and keep a User-Agent the caller supplies.

Signed-off-by: Will Pfleger <wpfleger@block.xyz>
Co-authored-by: Hayt <211b96e6a2b7f45fd4047988976c7bbbeeda0c15f3ae7b32eec20834b5a55118@buzz.block.builderlab.xyz>
@wpfleger96
wpfleger96 requested a review from a team as a code owner November 7, 2026 21:55
@wpfleger96
wpfleger96 deployed to codex-review November 7, 2026 21:55 — with GitHub Actions Active
@github-actions github-actions Bot added the codex-security-review-current The posted Codex security review matches its recorded range. label Nov 7, 2026
@github-actions

github-actions Bot commented Nov 7, 2026

Copy link
Copy Markdown

🔐 Codex Security Review

Note: This is an automated, security-focused review generated by Codex.
Use it as a supplement to human review; false positives are possible.

Scope

  • Exact PR diff: f3b127e3af5c14d2314faa2b63556c3f51ec6743...cf304085c1b8e363318903b613b29f37f6f4e250
  • Model: gpt-6.1-sol

💡 Click "edited" above to see earlier reviews for this PR.


Review Summary

Overall Risk: NONE

No concrete security, correctness, or reliability findings in the authorized PR range. The changes preserve authentication headers, host routing, and existing redirect protections.

Findings

No concrete security, correctness, or reliability findings were identified.

Notes

  • Review used read-only source inspection. Builds and tests were not run, as instructed.

Generated by Codex Security Review |
Requested by: @wpfleger96 |
Workflow run

This branch was successfully deployed

1 active deployment
codex-review — cf304085 Deployed Nov 7, 2026 by wpfleger96 via Run Codex Security Review #13778
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

codex-security-review-current The posted Codex security review matches its recorded range.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant