Course contentsShow
← Security
Lesson 1143 of 3,05223. Web Security - Modern Web AttacksFree lesson

Open Redirect Impact and Exploitation

Learning how open redirects enable phishing, OAuth token theft, and SSRF attacks through redirect chaining.

Open Redirect Impact and Exploitation

You'll learn: How attackers weaponize open redirects to steal credentials, tokens, and bypass security boundaries.

Why Open Redirects Are Dangerous

An open redirect seems harmless—just a URL sending users elsewhere, right? But when combined with legitimate domain trust, open redirects become powerful weapons. The key danger is trust transfer: victims trust your domain and attackers exploit that trust to deliver malicious payloads.

Real-World Attack Scenarios

Phishing Campaigns
Attackers send emails like https://trustedbank.com/redirect?url=evil.com/fake-login. Because the link starts with a trusted domain, spam filters and users are fooled. The open redirect acts as a trust laundering service.

OAuth Token Theft
OAuth flows redirect tokens to a registered redirect_uri. If https://victim.com/oauth/callback?redirect= has an open redirect vulnerability, attackers register:

redirect_uri=https://victim.com/oauth/callback?redirect=https://attacker.com

The OAuth provider validates the base domain, but the open redirect bounces the token (in URL fragment or query string) straight to the attacker.

SSRF via Redirect Chaining
Server-Side Request Forgery protection often whitelists external domains. An open redirect on a trusted domain bypasses this:

Attacker requests: https://trusted-partner.com/redir?to=http://internal-admin:8080
Server allows trusted-partner.com → redirect chains to internal network

Why Defenses Fail

Open redirects exploit the gap between initial validation and final destination. Security controls check the first hop, but attackers control the second hop.

Key Takeaway:
Open redirects transform trusted domains into attack infrastructure, enabling phishing, OAuth token theft, and SSRF through redirect chaining—all while bypassing security controls that only validate the initial URL.