Coder: Workspace agent API insecure redirect handling allowed cross-agent file read and write
- Published
- Last modified
- Where the record stands: published, rejected by its publisher, or superseded by another id.What do these mean? →
- published
- Whether CISA lists it in its Known Exploited Vulnerabilities catalog: proof that attackers are using it.What do these mean? →
- Not listed in CISA KEV
- Fix
- Fixed in 2.29.19, 2.32.9, 2.33.10, 2.34.4
- Whether working attack code is public (Exploit-DB, Metasploit, Nuclei or GitHub). Public code makes attacks easier.What do these mean? →
- None on Exploit-DB, Metasploit or GitHub
- Exploitation: none
- Automatable: no
- Technical impact: total
Summary
Coder allows organizations to provision remote development environments via Terraform. Prior to 2.29.19, 2.32.9, 2.33.10, and 2.34.4, agentConn.apiClient() follows redirects while its custom transport accepts the host from the redirected request URL when the port is the workspace agent HTTP API port 4. An authenticated user who controls a modified workspace agent and knows another online agent's UUID can derive the victim's tailnet address and redirect control-plane requests to that agent. HTTP 301, 302, and 303 redirects can redirect read requests, while HTTP 307 and 308 preserve replayable write and process-start requests. The redirected workspace agent file APIs can read or write files as the victim workspace user, and affected versions exposing the workspace agent process API can execute commands after a redirected file write, crossing workspace and tenant boundaries. This issue is fixed in versions 2.29.19, 2.32.9, 2.33.10, and 2.34.4.
Timeline
- CVE published
- CISA SSVC assessment
Exploitation: none · Automatable: no · Technical impact: total
- Record last updated
Affected versions
- coder coder
From 2.27.0 · fixed in 2.29.19; From 2.30.0 · fixed in 2.32.9; From 2.33.0 · fixed in 2.33.10; From 2.34.0 · fixed in 2.34.4
- github.com/coder/coderGo
All versions
- github.com/coder/coder/v2Go
From 2.27.0 · fixed in 2.29.19; From 2.30.0 · fixed in 2.32.9; From 2.33.0 · fixed in 2.33.10; From 2.34.0 · fixed in 2.34.4
- github.com/coder/coder/v2Go
From 2.34.0 · fixed in 2.34.4
- github.com/coder/coder/v2Go
From 2.33.0 · fixed in 2.33.10
- github.com/coder/coder/v2Go
From 2.30.0 · fixed in 2.32.9
- github.com/coder/coder/v2Go
From 2.27.0 · fixed in 2.29.19