CVE-2025-59956: AgentAPI exposed user chat history via a DNS rebinding attack

Published Sep 29, 2025
·
Updated

Summary AgentAPI prior to version 0.4.0 was susceptible to a client-side DNS rebinding attack when hosted over plain HTTP on localhost.

Impact An attacker could have gained access to the /messages endpoint served by the Agent API. This allowed for the unauthorized exfiltration of sensitive user data, specifically local message history, which could've included secret keys, file system contents, and intellectual property the user was working on locally.

Remediation We've implemented an Origin and Host header validating middleware and set a secure by default configuration.

Please upgrade to version 0.4.0 or later.

Credits We'd like to thank Evan Harris from mcpsec.dev for reporting this issue and following the coordinated disclosure policy.

Other sources

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.

MITRE

Affected Software

2 affected componentsFixes available
go/github.com/coder/agentapi<0.4.0
0.4.0
Coder AgentAPI<0.4.0

Event History

Sep 29, 2025
Advisory Published
via GitHub·08:40 PM
Data Sourced
via GitHub·08:40 PM
DescriptionSeverityWeaknessAffected Software
CVE Published
via MITRE·11:57 PM
Data Sourced
via MITRE·11:57 PM
DescriptionSeverityWeakness
Sep 30, 2025
Data Sourced
via NVD·11:37 AM
RemedyDescriptionSeverityWeaknessAffected Software

Frequently Asked Questions

1

What is the severity of CVE-2025-59956?

CVE-2025-59956 is considered a high severity vulnerability due to the potential for unauthorized access to sensitive endpoints.

2

How do I fix CVE-2025-59956?

To fix CVE-2025-59956, update the AgentAPI to version 0.4.0 or later.

3

What does CVE-2025-59956 exploit?

CVE-2025-59956 exploits a client-side DNS rebinding attack when the AgentAPI is hosted over plain HTTP on localhost.

4

What is the impact of CVE-2025-59956?

The impact of CVE-2025-59956 allows an attacker to access the /messages endpoint of the Agent API.

5

Which versions of AgentAPI are affected by CVE-2025-59956?

Versions of AgentAPI prior to 0.4.0 are affected by CVE-2025-59956.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203