Written by: Mio Kanzaki(Security Analyst (AI))Reviewed by: 千葉圭介Updated
An open redirect is a mechanism by which a genuine site's URL leads visitors to a fake site. MITRE's CWE-601 organises it as a weakness in web applications that use an outside link a user can specify as the redirect destination without checking it. What is exploited is that the URL begins with the real site's name, so visitors trust it.
How does an open redirect work?
Consider an information desk at a station that guides visitors to whatever destination they wrote on a note, without checking it. The desk's name badge is genuine, so visitors follow in confidence. If the destination is a fake building, the desk does not care.
A website is in the same state when a feature takes the redirect destination from a value in the URL. Features that return you to the original page after login, or that relay you to an outside link, can be the entrance.
OWASP gives four measures. The first is not to let users decide the destination. The second is to receive a short name or ID and map it on the server to a fixed URL. If an outside URL is needed, compare its scheme, host, port and path with allowed values.
The last is to put a confirmation screen showing the destination before the redirect. OWASP warns against simple checks that only match the start or end of a string. How to check is on the open redirect vulnerability page.
Why does an open redirect matter?
CWE-601 lists, as a possible result, sending users to a malicious page. A crafted link begins with the genuine server's name, so victims find it easier to trust. Visitors may be led to a phishing page that steals credentials or personal information.
The danger is that your own site becomes, as it stands, a tool in someone else's deception. Customers open it because they trust your name, and are harmed. Even if the fault lies elsewhere, it is your trust that is damaged.
This weakness is hard to notice by sight. The screens work normally, so an assessment is the practical way to check. If you first want to see what your site shows from outside, the free URL check uses only information anyone can see.
Related terms
- Phishing: leading visitors to a fake site to steal IDs and card numbers.
- SSRF: a server-side weakness that shares the problem of an outside destination going unchecked.
Next step
List the features on your site that take the redirect destination from the URL. How to check and fix them is on the open redirect vulnerability page, and preparation against phishing is in phishing measures. To talk about an assessment, contact us.
Frequently asked questions
Is an open redirect a hole that lets the site's data be stolen?
It does not steal the site's data directly. It turns the genuine site's URL into a tool for taking visitors to a fake page. As a result, a visitor's ID or card number may be stolen.
Is it enough to check that the destination URL starts with our own domain?
Not enough. OWASP warns against simple checks that only match the start or end of a string. Decide the allowed destinations in advance and match them in full.
Frequently asked questions
Is an open redirect a hole that lets the site's data be stolen?
It does not steal the site's data directly. It turns the genuine site's URL into a tool for taking visitors to a fake page. As a result, a visitor's ID or card number may be stolen.
Is it enough to check that the destination URL starts with our own domain?
Not enough. OWASP warns against simple checks that only match the start or end of a string. Decide the allowed destinations in advance and match them in full.