CVE-2025-59956 Details
Description
AgentAPI is an HTTP API for Claude Code, Goose, Aider, Gemini, Amp, and Codex. Versions 0.3.3 and below are susceptible to a client-side DNS rebinding attack when hosted over plain HTTP on localhost. An attacker can gain access to the /messages endpoint served by the Agent API. This allows for the unauthorized exfiltration of sensitive user data, specifically local message history, which can include secret keys, file system contents, and intellectual property the user was working on locally. This issue is fixed in version 0.4.0.
A client-side DNS rebinding vulnerability has been identified in Coder's AgentAPI, an HTTP API for various AI coding agents. This vulnerability affects versions prior to 0.4.0 and occurs when the API is hosted over plain HTTP on localhost. The flaw allows attackers to manipulate the victim's browser into interacting with the vulnerable API, specifically the /messages endpoint, which can lead to unauthorized access and exfiltration of sensitive user data, including secret keys, local file system contents, and intellectual property. The vulnerability is easily exploitable within seconds of connecting to a malicious server.
Users are advised to update to AgentAPI version 0.4.0 or later, which includes a validation middleware for the Origin and Host headers, and sets a secure default configuration. Instructions for updating can be found in the release notes on the AgentAPI GitHub repository.
Metrics
CVSS 4.0 Severity and Vector Strings:
No CVSS 4.0 data is available for this CVE.
CVSS 3.x Severity and Vector Strings:
No data available for CVSS Version 2.0 on this CVE.
CISA-ADP
Assessed Sep 30, 2025References to Advisories, Solutions, and Tools
By selecting these links, you will be leaving this site. These are references gathered from the official CVE record and are not endorsed by Volerion.
| URL | Source(s) | Tag(s) |
|---|---|---|
| https://mcpsec.dev/advisories/2025-09-19-coder-chat-exfiltration/ | CISA-ADP | ExploitThird Party Advisory |
| https://github.blog/security/application-security/localhost-dangers-cors-and-dns-rebinding | [email protected] | Technical Description |
| https://github.com/coder/agentapi/commit/5c425c62447b8a9eac19e9fc5a2eae7f0803f149 | [email protected] | Patch |
| https://github.com/coder/agentapi/pull/49 | [email protected] | Issue TrackingPatch |
| https://github.com/coder/agentapi/releases/tag/v0.4.0 | [email protected] | Release Notes |
| https://github.com/coder/agentapi/security/advisories/GHSA-w64r-2g3w-w8w4 | [email protected] | PatchVendor Advisory |
| https://mcpsec.dev/advisories/2025-09-19-coder-chat-exfiltration | [email protected] | ExploitThird Party Advisory |
Weakness Enumeration
| CWE-ID | CWE Name | Source |
|---|---|---|
| CWE-290 | Authentication Bypass by Spoofing | [email protected] |
| CWE-350 | Reliance on Reverse DNS Resolution for a Security-Critical Action | [email protected] |
Affected Products
| Product | Versions |
|---|---|
| coder agentapi | < 0.4.0 |
CPE
Remediation
| |
Change History
5 change records found show changes
| Date | Action | Recorded By |
|---|---|---|
| Jun 17, 2026 | CVE Modified | [email protected] |
| Jun 17, 2026 | CVE Modified | CISA-ADP |
| Oct 8, 2025 | Initial Analysis | [email protected] |
| Sep 30, 2025 | CVE Modified | CISA-ADP |
| Sep 30, 2025 | New CVE Received | [email protected] |