← back to room
SSRF
SSRF Domain Allowlist Bypass
Scenario
Policy now requires every URL to contain the corporate domain name. The validator searches the full string rather than parsing authority components. Still reach the internal metadata host while satisfying the substring rule.
Your approach
- Observe rejection when the url lacks the trusted domain text.
- Craft URLs where the domain string appears but another host is contacted.
- Fetch internal metadata through the allowed-looking URL.
- Copy the flag from the successful response.
- Submit the SSRF flag.
Only URLs containing hackerz-labs.test are allowed, but the check is naive. Bypass it with userinfo: http://hackerz-labs.test@169.254.169.254/.
Sandbox note: all fetches hit a simulated internal network; no real requests leave the server.
Sandbox note: all fetches hit a simulated internal network; no real requests leave the server.