QuantumNous new-api SSRF Bypass via 0.0.0.0
The QuantumNous new-api is vulnerable to SSRF attacks. The SSRF protection implemented in versions v0.9.0.5 (CVE-2025-59146) and v0.9.6 (CVE-2025-62155) can be bypassed by using the address `0.0.0.0`. An attacker with a valid API token can send a request to `/v1/chat/completions`, `/v1/responses`, or `/v1/messages` with `0.0.0.0` as the image/file URL host, which bypasses the private-IP filter and allows the server to issue HTTP requests to localhost, enabling a blind SSRF and possibly a full-read SSRF in specific configurations.
The QuantumNous new-api is vulnerable to a Server-Side Request Forgery (SSRF) vulnerability due to an incomplete fix for previous SSRF issues (CVE-2025-59146, CVE-2025-62155). The vulnerability exists in versions up to 0.11.9-alpha.1. The SSRF protection implemented in v0.9.0.5 and hardened in v0.9.6 fails to block the address 0.0.0.0, which resolves to localhost on Linux systems. An authenticated, regular user with any valid API token can exploit this by sending a request to specific endpoints such as /v1/chat/completions including 0.0.0.0 in the URL of an image or file. If the request is routed through an AWS/Bedrock Claude adaptor, this can be upgraded to a full-read SSRF where the fetched content is inlined into the model response, allowing for exfiltration of internal content.
Attack Chain
- An attacker obtains a valid API token for a regular user account on the QuantumNous new-api.
- The attacker crafts a POST request to
/v1/chat/completionswith a JSON payload that includes a maliciousimage_urlwith the host set to0.0.0.0and a port in the allowed list (80, 443, 8080, 8443). For example:"url": "http://0.0.0.0:8080/probe.png". Thestream: trueparameter is also set to trigger the fetch path. - The server-side code at
dto/openai_request.gorecognizes thehttp(s)://URL as a valid source and proceeds to collect metadata. - The
LoadFileSource()function atservice/token_counter.godetermines that the file needs to be fetched based on theshouldFetchFilessetting. - The
loadFromURL()function withinservice/file_service.gocallsDoDownloadRequest(). - The
ValidateURLWithFetchSetting()function atservice/download.goincorrectly validates the URL, as0.0.0.0is not blocked by the IP filter. - The server initiates a TCP connection to
0.0.0.0on the specified port. - If the request is routed through an AWS/Bedrock Claude channel, the fetched content from
0.0.0.0is then inlined into the model request and leaked through the model’s response (full-read SSRF). Otherwise, an attacker can probe internal services.
Impact
An attacker with a valid user API token can exploit this SSRF vulnerability to probe internal services and potentially exfiltrate sensitive information. By bypassing the intended SSRF protections, the attacker can access resources on the localhost that should not be exposed. If the request is processed by a multimodal model like Claude via AWS/Bedrock, the fetched content can be directly leaked through the model’s output, leading to full-read SSRF. The vulnerability can be exploited by any registered user since user registration is often enabled by default.
Recommendation
- Apply a patch that adds
0.0.0.0/8to the deny list inisPrivateIP()as suggested in the advisory. - Deploy the Sigma rule “Detect QuantumNous new-api SSRF Attempt via 0.0.0.0” to detect attempts to exploit this vulnerability by monitoring network connections to 0.0.0.0.
- Block the URLs
http://0.0.0.0:8080/probe.pngandhttps://dummyimage.com/600x180/111/fff.png&text=READBACK-OK-314159at the network perimeter to prevent exploitation. - Upgrade to a version of the QuantumNous new-api that includes a fix for CVE-2026-42339.
Detection coverage 2
Detect QuantumNous new-api SSRF Attempt via 0.0.0.0
highDetects network connections to 0.0.0.0 which can indicate an SSRF attempt in QuantumNous new-api.
Detect SSRF via Image URL with 0.0.0.0
highDetects SSRF attempts by monitoring web server logs for requests containing 'image_url' with a URL pointing to 0.0.0.0 in QuantumNous new-api.
Detection queries are available on the platform. Get full rules →
Indicators of compromise
2
url
| Type | Value |
|---|---|
| url | http://0.0.0.0:8080/probe.png |
| url | https://dummyimage.com/600x180/111/fff.png&text=READBACK-OK-314159 |