Hijacking Reset Password Link in https://www.niteflirt.com/ via Host Header Poising (Write Up)
The reset password page used the Host header to build the password reset link, so an attacker could change the Host header to make the link point to a domain they control. A victim clicking the poisoned link would send their reset token to the attacker, who could then take over the account.
Published on blog.evanricafort.com
Summer last year while playing with google dorks I found a random external bug bounty program which is an adult website that allow user to interact each other through chat. The app is similar to tinder.
The full write-up lives on its author's site
It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
How it worked
Root cause
Likely the application trusted the client-supplied Host header when generating the password reset URL instead of using a fixed, configured domain.
Impact
An attacker could make the password reset email contain a link to a domain they control, so a victim who clicks it would send their reset token to the attacker, potentially leading to account takeover.
What the attacker needed
A free account; victim clicks the poisoned reset link
How it was found
- Sign up for an account on the site.
- Go to the reset password page.
- Intercept the reset password request and change the Host header value.
- Submit the request and observe the reset password link in the email now points to the changed host.
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 write-up has not been written yet. The Original tab links to the source.
When you forget your password, a website emails you a special link to reset it. This site built that link using a value called the Host header, which the visitor's browser sends and which can be changed. By changing it, an attacker could make the email contain a link to their own site, so when the victim clicks it the secret reset code goes to the attacker.
What is Account takeover?
Getting into someone else's account through a flaw in sign-in, password reset, second factor, single sign-on or session handling.