How a Single HTTP Redirect Bypassed SSRF Filters on 4 Programs Over 8 Years
The article describes a recurring SSRF bypass where an application validates a user-supplied URL but then follows HTTP redirects without re-checking the destination, allowing access to internal services. Across four programs, attackers used a redirect to reach localhost or cloud metadata endpoints and read internal responses.
That’s the gap between the earliest disclosed report using this exact technique and the most recent one. Same bypass.
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 write-up has not been written yet. The Original tab links to the source.
How it worked
Root cause
The SSRF filter validates only the initial URL, while the HTTP client follows redirects by default without re-validating the final destination.
Impact
An attacker could reach internal services or cloud metadata and, in the Rocket.Chat case, read portions of an internal service's response in a chat preview; in other cases the impact was blind or limited to port scanning.
What the attacker needed
An endpoint that fetches user-supplied URLs; ability to host or use a redirect; SSRF filter present but not re-checking redirects
The fix
The fix should re-validate the final URL after every redirect, or disable redirect following, and bind the request to the already-verified IP address.
How it was found
- Find an endpoint that fetches a URL you control.
- Confirm the SSRF filter blocks direct internal IPs.
- Set up a redirect to an internal target.
- Submit the redirect URL to the endpoint.
- The filter checks the external URL and passes it.
- The HTTP client follows the redirect and fetches the internal resource.
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 write-up has not been written yet. The Original tab links to the source.
SSRF (server-side request forgery) is when a server fetches a URL on your behalf, and you trick it into fetching something internal that you cannot reach directly. Here, the server checked the first URL you gave it, but when that URL redirected to an internal address, the server followed the redirect without checking again. That let attackers see internal services or cloud metadata.
What is SSRF?
The server can be made to fetch an address the attacker chooses, reaching internal services, cloud metadata or other customers' data.