Skip to content
SSRF Disclosed report Intermediate

The endpoint '/test/webhooks' is vulnerable to DNS Rebinding

The webhook endpoint accepted a URL whose domain could alternate between an external IP and localhost, bypassing the check that blocks private addresses. An attacker could make the server send requests to internal services, a blind SSRF.

sim4n6 Follow

Originally disclosed on HackerOne

  • Triaged in 20 hours
  • Fixed in 38 days
  • Paid in 37 days
  • Disclosed after 5 months

Summary:

DNS rebinding attack is a method of switching the resolution of domain names as wished by the attacker. The aim is to lure the web app to a different IP address/host. In this attack, and particularly in our case, a malicious server will first perform a domain name resolution to the IP address of 178.62.122.208 (a random HTTP server that is valid as a Web-hook for Omise web-app) and than rebind to an internal IP address 127.0.0.1, thus, bypassing firewall protection.

The malicious link is https://A.178.62.122.208.1time.127.0.0.1.1time.repeat.rebind.network/webhook5 can be depicted as follow:

  1. Initial resolution of the IP address will point to 178.62.122.208 for the first time.
  2. The second time, the malicious DNS server will resolve to 127.0.0.1 for one time. 3.The next time the DNS server will switch back the first IP address. And so on.

When a user uses a private IP address an error will be displayed, the web app recognizes that the web-hook endpoint is either insecure or forbidden. However, DNS rebinding attack will bypass this protection.

Steps To Reproduce:

  1. Create an account at Omise.co and go to https://dashboard.omise.co/test/webhooks
  2. Add the following endpoint https://A.178.62.122.208.1time.127.0.0.1.1time.repeat.rebind.network/webhook5 as an external web-hook.

In case, the malicious DNS server resolves initially the previous URL to 127.0.0.1 you will get this error:

w1.png
w1.png From the original on HackerOne

In case, it resolves initially to the other IP address. It will be saved.

w2.png
w2.png From the original on HackerOne

Supporting Material/References:

Impact

This is a Blind SSRF, since the malicious URL induces the server side to perform a request to an internal endpoint each time a recent activity is fired such as Create a recipient. Furthermore, the malicious URL can be further personalized (replace webhook5 with else/internal to get https://127.0.0.1/else/internal).

The original report as published on HackerOne, by sim4n6. Images and videos are our own copies; raw HTML is shown as text. View it on HackerOne.

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

Likely the webhook URL validation only checked the hostname or the first DNS resolution, not every resolved address at request time, so a rebinding domain could later resolve to localhost.

Impact

This is a blind SSRF: the server could be made to request internal endpoints whenever a webhook-triggering action occurs, and the path could be customised to reach other internal services.

What the attacker needed

An account on the platform; ability to add a webhook URL; a rebinding DNS service

How it was found

  1. Create an account and open the test webhooks page.
  2. Add the rebinding domain URL as an external webhook.
  3. If the domain first resolves to localhost, an error is shown; if it first resolves to the external IP, the webhook is saved.

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.

A webhook is a URL the server calls when something happens. The site tried to block webhook URLs pointing at its own internal network, but an attacker can use a special domain that changes which address it points to. That tricks the server into calling itself, which can expose internal services.

What is SSRF?

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

More by sim4n6

View all

5 more disclosed reports, best first.

More from Omise

View all

The newest disclosed reports for this program.

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.