Gopeed's proxy endpoint makes destination validation the real SSRF control

Gopeed is a download manager with a local web interface and a proxy endpoint. CVE-2026-138331 affects Gopeed through version 2.0.0-beta.3. The CVE record identifies DoProxy in pkg/rest/api.go and says manipulation of the X-Target-Uri argument leads to server-side request forgery. The assigning CNA records a CVSS 4.0 score of 6.9.

SSRF matters because the request leaves the user's browser and is made by the Gopeed process. That process may be able to reach loopback services, a private management network, a cloud metadata address, or an internal file service that never accepts connections from the public internet. The response might be returned to the caller, stored as a download, or revealed through timing and error text. Even a blocked response can disclose whether an internal address exists.

The vulnerable endpoint accepts a target URI through a header, which makes destination policy easy to miss. A simple string check for localhost is insufficient. Attackers can use alternate IP encodings, IPv6 loopback forms, DNS names that resolve to private addresses, redirects, or DNS rebinding. The validation should operate on the resolved address used for the connection, not on the original hostname alone. Redirects should be disabled by default or revalidated after every hop.

Gopeed's repository references pull request 1596 and commit 4214765d3966e72e1315b8d78eca23d47fe36a27 in public vulnerability records. Operators should move to a build that includes the reviewed change. If the web interface is enabled, bind it to loopback or a trusted management network instead of a public interface. Require authentication where supported and review whether a browser session or CSRF token can reach the proxy route.

Network policy should provide a second barrier. The Gopeed process should not have broad access to internal subnets or the cloud metadata service. Place it in a network namespace that can reach only the destinations needed for downloads and updates. Deny link-local addresses and private ranges by default unless the product's purpose explicitly requires them. Log the resolved peer address, not only the requested URL.

The download path adds a storage risk. A successful SSRF can pull an attacker-controlled file into the host's download directory. Treat downloaded content as untrusted, scan it, and keep execution away from the download path. If the deployment uses a shared volume, confirm that a file fetched through the proxy cannot overwrite a configuration file or another user's artifact.

Testing should include the destinations that a text filter often misses. Resolve a hostname to a private address, send a redirect to loopback, try an IPv6 local address, and use a DNS name that changes resolution between validation and connection. A successful check should return a policy denial based on the final connection target. It should not return a generic network error that leaves the operator unsure whether the request was blocked or simply failed.

The public record does not establish that every Gopeed installation is reachable from the internet. It establishes that the proxy code mishandles a caller-supplied target in affected versions. Upgrade, bind the interface carefully, block private destinations at the process boundary, and verify the final resolved address before sending the request.

References