Skip to content
Open redirect Disclosed report Beginner

[ecommerce.shopify.com] Invalidated redirection

The return_to parameter on the Shopify ecommerce authentication endpoint accepted a value with multiple forward slashes, bypassing redirection protection. An attacker could redirect a victim to an external website after the victim clicked either the link or reject button.

shailesh4594 Follow

Originally disclosed on HackerOne

  • Triaged in 28 hours
  • Fixed in 10 days
  • Paid in 29 days
  • Disclosed after 54 days

Summary by the researcher

Bypassed redirection protection using 5 forward slashes!

The report

Hello,

Endpoint : https://ecommerce.shopify.com/auth/shopify?shop=[victim_shop].myshopify.com&return_to=/////example.com

Suppose, victim has not linked his shop with ecommerce.shopify.com portal then an attacker can redirect him on an external website after linking or rejecting.

Steps to reproduce :

  1. Get logged in as admin in your shop and ecommerce.shopify.com
  2. Open this link : https://ecommerce.shopify.com/auth/shopify?shop=[your-shop].myshopify.com&return_to=/////example.com
  3. If you are logged in then Link These Accounts button and No thanks link will be shown.
  4. Click on Link Account button or No thanks link.
  5. You will be redirected on https://example.com instead of ecommerce.shopify.com
  6. Done

Again, your shop should not be linked to ecommerce.shopify.com.

Suggested Fix : Use more stronger regular expression at this endpoint

Best regards, Shailesh

The original report as published on HackerOne, by shailesh4594. 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 redirection validation used a regular expression that did not correctly handle multiple leading forward slashes, allowing an external URL to pass as a relative path.

Impact

An attacker could redirect a victim to an external website after the victim clicks either the link or reject button, which could be used for phishing.

What the attacker needed

Victim is logged in as admin; shop not linked to ecommerce.shopify.com; victim clicks a crafted link

How it was found

  1. Log in as admin to your shop and ecommerce.shopify.com.
  2. Open the crafted link with the return_to parameter containing multiple slashes.
  3. If logged in, the page shows 'Link These Accounts' and 'No thanks' options.
  4. Click either the link button or the 'No thanks' link.
  5. You are redirected to the external site instead of ecommerce.shopify.com.

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.

A redirect is a web feature that sends you to another page after an action. Here, the site was supposed to only redirect to its own pages, but a crafted link with extra slashes tricked it into sending users to an outside site. This matters because attackers can use such redirects to make phishing links look trustworthy.

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.

More by shailesh4594

View all

4 more disclosed reports, best first.

More from Shopify

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Open redirect

The lesson behind this report.

A trusted site forwards users to any address an attacker picks; rarely paid alone, often the missing link in a chain.