Skip to content
SSRF Write-up Intermediate

A Real SSRF Story from HackerOne (Featuring IPv6 + Redirects)

A webhook feature accepted user-supplied URLs and followed redirects without re-validating the final destination, and its filter only blocked internal IPv4 addresses in decimal form. By redirecting to an IPv6-mapped representation of an internal address, the researchers could make the server reach internal services and scan ports.

medium.com

Published on medium.com

In the world of web security, even the most seemingly harmless features like webhooks can hide critical vulnerabilities. In this article, we take a deep dive into a Server-Side Request Forgery (SSRF) bug discovered in a webhook implementation.

Red Darkin, on medium.com

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

Likely the webhook followed redirects without re-validating the final destination and its blocklist only covered decimal IPv4 forms, missing IPv6-mapped and octal representations.

Impact

The server could be made to reach internal services and scan ports, though responses were inconsistent and no further exploitation is claimed.

What the attacker needed

A webhook feature that fetches user URLs; attacker-controlled redirect server; ability to submit a URL to the webhook

The fix

The webhook should re-validate the final destination after every redirect and normalise or block all IP representations, not just decimal IPv4.

How it was found

  1. Find a webhook feature that accepts user-controlled URLs and makes server-side requests.
  2. Observe that direct internal addresses in decimal form are blocked.
  3. Host a redirector that sends the request to an internal address written in IPv6-mapped form.
  4. Submit the redirector URL to the webhook and confirm the server follows it to the internal destination.
  5. Probe internal ports manually because timing was unreliable.

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.

A webhook is a feature where a website asks its own server to fetch a URL you give it. If the site does not carefully check where that URL finally points, an attacker can make the server visit internal machines that outsiders cannot reach. Here the check only looked for one common way of writing internal addresses, so a different way of writing the same address slipped through.

What is SSRF?

The server can be made to fetch an address the attacker chooses, reaching internal services, cloud metadata or other customers' data.

Similar reports

View all

Same bug class and techniques, clearest first.

Server-side request forgery (SSRF)

The lesson behind this report.

The server can be made to fetch an address the attacker chooses, reaching internal services, cloud metadata or other customers' data.