Skip to content

fix: send coder User-Agent on workspace app icon fetches - #268

Open
ethanndickson wants to merge 2 commits into
mainfrom
ethan/icon-user-agent
Open

fix: send coder User-Agent on workspace app icon fetches#268
ethanndickson wants to merge 2 commits into
mainfrom
ethan/icon-user-agent

Conversation

@ethanndickson

Copy link
Copy Markdown
Member

Follow up to #264.

Workspace app icons are fetched by SDWebImage rather than Client, so they never picked up the coder-desktop/<version> (darwin/<arch>) User-Agent. SDWebImage sets its own default (Coder Desktop/<version> (Mac OS X ...)) instead, and relative icon URLs resolve to the deployment host, so these requests can be blocked by the same WAF rule.

The fix is just to set the header once on SDWebImageDownloader.shared at launch, next to where we register the SVG coder. I've made the one-argument userAgent(component:) public so the app target can reach it, whilst keeping the version:/arch: test knobs internal.

Icon URLs can be third-party, but the User-Agent carries nothing sensitive, so unlike literal headers it's fine to send it everywhere.

@ethanndickson
ethanndickson marked this pull request as ready for review September 9, 2026 12:50
@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review Completed 2026-09-09T12:54:06.959666Z 6a48bd3 Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@ethanndickson
ethanndickson requested a review from untra September 9, 2026 13:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants