Files
coder/coderd/coderdtest
dylanhuff-at-coder b5ce79b9e0 fix(coderd): validate GCP instance token audience (#29765)
Google instance identity authentication accepted tokens issued for any
audience. A Google-signed token for a registered VM but intended for
another service could therefore be exchanged for a Coder agent token.

Require `aud=coder` before the exchange. The standard GCP agent already
requests this audience. Custom clients requesting another audience will
receive 401 and need to update. Add coverage for foreign-audience
rejection and the returned agent token.

Refs
https://linear.app/codercom/issue/PLAT-655/fixcoderdworkspaceresourceauth-validate-audience-on-gcp-instance
2026-09-24 11:41:32 -07:00
..