GHSL-2024-340: Server-Side Request Forgery (SSRF) in Sonatype Nexus 2 - CVE-2025-9868
The Remote Browser Plugin in Sonatype Nexus 2 accepts an arbitrary URL from the request path and makes an HTTP GET request to it, reusing the proxy repository's stored credentials. An unauthenticated attacker could therefore make the server send requests to any host and, if the proxy repository has basic authentication configured, leak those credentials to an attacker-controlled server.
Originally disclosed on GitHub Security Lab
A Server-Side Request Forgery (SSRF) vulnerability was discovered in Sonatype Nexus 2, allowing an unauthenticated attacker to send arbitrary HTTP GET requests to any URL, potentially leaking sensitive information such as passwords. This vulnerability is caused by the RemoteBrowserResource.java controller accepting…
The full write-up lives on its author's site
It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
How it worked
Root cause
The controller takes the user-supplied path as a full remote URL and the HTTP client reuses the proxy repository's authentication context, so credentials are sent to whatever host the attacker specifies.
Impact
An unauthenticated attacker could send arbitrary HTTP GET requests to any URL and, if the proxy repository uses basic authentication, leak those credentials to an external host; the plugin is enabled by default.
What the attacker needed
Nexus 2 with Remote Browser Plugin enabled; A proxy repository configured with basic auth; Attacker can reach the Nexus instance
The fix
Sonatype stated that Nexus Repository Manager 2 is sunset and will not release a fix for this issue.
How it was found
- Start a Nexus instance listening on a local port.
- Create a proxy repository pointing to a remote Maven repository with basic authentication enabled.
- Run a server on a separate host that responds with a 401 challenge and logs any Authorization header.
- Send a request to the remotebrowser endpoint with the attacker server's URL in the path.
- Observe the leaked username and password in the attacker server's logs.
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
Server-Side Request Forgery (SSRF) is when a server is tricked into making a request to a destination the attacker chooses. Here, a part of the web address is treated as a full URL, so the server fetches that URL instead of a file from the repository. Because the server also attaches the saved login details for the proxy repository, those details can be sent to the attacker's server.
What is SSRF?
The server can be made to fetch an address the attacker chooses, reaching internal services, cloud metadata or other customers' data.