9.1critical
Coder: PKCS#7 signature bypass in Azure instance identity allows unauthenticated agent token theft
- Severity
- 9.1critical CVSS:3.1 by GitHub_M
- Exploit likelihood
- 0.36% (higher than 32% of CVEs; EPSS, by FIRST)
- Published
- Last changed
- Assigned by
- GitHub_M
- Also known as
- GHSA-6x44-w3xg-hqqfGO-2026-5196
Description
Coder allows organizations to provision remote development environments via Terraform. In versions prior tp 2.24.5, 2.29.13, 2.30.8, 2.31.12, 2.32.2, and 2.33.3, `azureidentity.Validate()` verifies that the PKCS#7 signer certificate chains to a trusted Azure CA but never verifies the PKCS#7 signature itself. An attacker can embed a legitimate Azure certificate alongside arbitrary content e.g. `{"vmId":"<target>"}` and the forged `vmId` will be accepted returning the victim workspace agent's session token. No authentication is required. The attacker only needs to know a target VM's `vmId` which is a `UUIDv4`. That's a practical limitation which would typically require prior access to be exploited. Versions 2.24.5, 2.29.13, 2.30.8, 2.31.12, 2.32.2, and 2.33.3 patch the issue. As a workaround, reconfigure any Azure templates to use token authentication rather than `azure-instance-identity`.
Affected
| Product or package | Versions | Reported by |
|---|---|---|
| coder coder | >= 2.33.0-rc.0, < 2.33.3, >= 2.32.0-rc.0, < 2.32.2, >= 2.31.0, < 2.31.12, >= 2.30.0, < 2.30.8, >= 2.29.0, < 2.29.13, < 2.24.5, before 2.24.5, from 2.29.0 before 2.29.13 and 4 more | CVE List, NVD |
| github.com/coder/coder/v2 (Go) | from 2.33.0-rc.0 before 2.33.3, from 2.32.0-rc.0 before 2.32.2, from 2.31.0 before 2.31.12, from 2.30.0 before 2.30.8, from 2.29.0 before 2.29.13, before 2.24.5 | GitHub Advisory Database, Go Vulnerability Database |
| github.com/coder/coder (Go) | up to 0.27.3, all versions | GitHub Advisory Database, Go Vulnerability Database |
All scores
| GitHub_M | 9.1critical CVSS:3.1 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N |
| GitHub | 9.1critical CVSS:3.1 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N |
Classification
SSVC (CISA-ADP): exploitation none, automatable yes, technical impact total.
What each source says
CVE List
Coder allows organizations to provision remote development environments via Terraform. In versions prior tp 2.24.5, 2.29.13, 2.30.8, 2.31.12, 2.32.2, and 2.33.3, `azureidentity.Validate()` verifies that the PKCS#7 signer certificate chains to a trusted Azure CA but never verifies the PKCS#7 signature itself. An attacker can embed a legitimate Azure certificate alongside arbitrary content e.g. `{"vmId":"<target>"}` and the forged `vmId` will be accepted returning the victim workspace agent's session token. No authentication is required. The attacker only needs to know a target VM's `vmId` which is a `UUIDv4`. That's a practical limitation which would typically require prior access to be exploited. Versions 2.24.5, 2.29.13, 2.30.8, 2.31.12, 2.32.2, and 2.33.3 patch the issue. As a workaround, reconfigure any Azure templates to use token authentication rather than `azure-instance-identity`.
GitHub Advisory Database
Summary
azureidentity.Validate() verifies that the PKCS#7 signer certificate chains to a trusted Azure CA but never verifies the PKCS#7 signature itself. An attacker can embed a legitimate Azure certificate alongside arbitrary content e.g. {"vmId":"<target>"} and the forged vmId will be accepted returning the victim workspace agent's session token.
No authentication is required. The attacker only needs to know a target VM's vmId which is a UUIDv4.
that's a practical limitation which would typically require prior access to be exploited
Root Cause
In unpatched Coder releases the signature over the PKCS#7 content is not validated - only the signing certificate is checked.
Impact
An attacker on any Azure VM or with access to a publicly available Azure IMDS certificate from CT logs can:
- Steal an agent session token by sending a forged PKCS#7 envelope to
POST /api/v2/workspaceagents/azure-instance-identitywhich is unauthenticated. - With the stolen token access:
- Git SSH private key via
GET /workspaceagents/me/gitsshkey: push to repositories and impersonate the workspace owner. - OAuth access tokens via
GET /workspaceagents/me/external-auth: GitHub, GitLab, and Bitbucket tokens in plaintext. - Workspace secrets via the agent manifest: environment variables, file paths, and API keys.
- Git SSH private key via
Attack Path Diagram
PKCS7_diagram (1)Affected Versions
All versions of Coder v2 are affected.
Patches
Fixed in #25286
The fix was backported to all supported release lines:
Workarounds
If unable to patch we recommend immediately reconfiguring any Azure templates to use token authentication rather than azure-instance-identity until the patch is released and you are fully upgraded.
- Modify the
coder_agent.authvalue to betoken. - Add
CODER_AGENT_TOKEN=${coder_agent.main.token}to the set of environment variables for the Coder Workspace Agent initialization script.
Recognition
We'd like to thank Ben Tran of calif.io and Anthropic’s Security Team (ANT-2026-22445) for independently disclosing this issue!
Go Vulnerability Database
Coder: PKCS#7 signature bypass in Azure instance identity allows unauthenticated agent token theft in github.com/coder/coder
References
| https://github.com/coder/coder/security/advisories/GHSA-6x44-w3xg-hqqf | advisory, patch, vendor-advisory, web | |
| https://github.com/coder/coder/pull/25286 | fix, issue-tracking, patch, web | |
| https://github.com/coder/coder/releases/tag/v2.24.5 | release-notes, web | |
| https://github.com/coder/coder/releases/tag/v2.29.13 | release-notes, web | |
| https://github.com/coder/coder/releases/tag/v2.30.8 | release-notes, web | |
| https://github.com/coder/coder/releases/tag/v2.31.12 | release-notes, web | |
| https://github.com/coder/coder/releases/tag/v2.32.2 | release-notes, web | |
| https://github.com/coder/coder/releases/tag/v2.33.3 | release-notes, web | |
| https://github.com/coder/coder | package | |
Sources
| Source | Record | Licence |
|---|---|---|
| CVE List | CVE-2026-46354 changed 2026-07-08 | CVE Terms of Use |
| GitHub Advisory Database | GHSA-6x44-w3xg-hqqf changed 2026-06-25 | CC-BY-4.0 |
| Go Vulnerability Database | GO-2026-5196 changed 2026-06-25 | CC-BY-4.0 |
| NVD | CVE-2026-46354 changed 2026-07-08 | Public domain |