Open Redirect on lovable.dev via redirect parameter leads to phishing attacks
The login redirect parameter on lovable.dev accepted a backslash-prefixed value and sent the user to an external domain instead of a relative path. An attacker could craft a lovable.dev link that redirects victims to arbitrary sites for phishing.
- Triaged in 4 hours
- Fixed in 14 hours
- Disclosed after 3 days
Summary:
An open redirect exists on lovable.dev. After logging in, a request is sent to 'https://lovable.dev/auth/post-login?redirect=%2F%3Fshould-refresh-credentials%3D1&_rsc=1b5jt'. Changing the redirect URL to /\google.com (https://lovable.dev/auth/post-login?redirect=/\google.com), for instance, allows a redirect to be performed to google.com. The application expects a relative path, but supplying a backslash-prefixed value (e.g., /\google.com) results in a redirect to an external domain (https://google.com).
This open redirect allows an attacker to craft URLs on the lovable.dev domain that redirect users to arbitrary external sites, which could be used in phishing campaigns or social engineering attacks.
Note:
This vulnerability also exists at https://lovable.dev/purchase-success?redirect=/%5Cgoogle.com.
Steps To Reproduce:
- Login to an account
- Visit https://lovable.dev/auth/post-login?redirect=/\google.com
- You will be redirected to google.com
Supporting Material/References:
[list any additional material (e.g. screenshots, logs, etc.)]
- [attachment / reference]
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 redirect handler only checked for a leading slash and did not normalise backslashes, so a value beginning with a slash and backslash was treated as a relative path but resolved to an external host.
Impact
An attacker could use lovable.dev links to send users to arbitrary external sites, which may aid phishing or social engineering.
What the attacker needed
An account; victim clicks a crafted lovable.dev link
How it was found
- Log in to an account.
- Visit the post-login URL with the redirect parameter set to a backslash-prefixed external domain.
- Observe the browser being redirected to the external domain.
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.
An open redirect is when a website takes a link parameter and sends you to whatever address is in it, even one outside the site. Here the site meant to accept only its own pages, but a backslash trick made it treat an outside address as allowed. Attackers use this to make harmful links look like they belong to the trusted site.
What is Open redirect?
A trusted site forwards users to any address an attacker picks; rarely paid alone, often the missing link in a chain.