Skip to content
Account takeover Disclosed report Intermediate

password less login token expiration issue

A passwordless login token generated via the Shopify iOS app remained valid even after the user revoked the app's access. An attacker who had obtained such a token could still log in and access the user's data.

satishb3 Follow

Originally disclosed on HackerOne

Bounty$500 View original
  • Triaged in 7 days
  • Fixed in 14 days
  • Paid in 20 days
  • Disclosed after 20 days
  1. Log into Shopify iOS app as Alice and grab the token.

  2. Send the below request to generate the password less login token (The token expires after a single use. So don't use the token).

    Request: POST /admin/api/graphql HTTP/1.1 Host: seclearn.myshopify.com Content-Type: application/graphql Connection: close X-Shopify-Access-Token: f263fb8c544a4cb965d63635a2e1c772 Accept: application/json User-Agent: Shopify Mobile/iPhone OS/5.0 (iPhone6,2/com.jadedpixel.shopify) Content-Length: 66 Accept-Language: en-us Accept-Encoding: gzip, deflate

    mutation{adminPasswordlessLogin(input:{}){passwordlessLoginToken}}

    Response: {"data":{"adminPasswordlessLogin":{"passwordlessLoginToken":"bd7ffa6c5bf2969fa15753f8fb8cb427-1475133135"}}}

  3. From desktop browser, login as Alice and revoke access to Shopify iOS app. It is revoking the access token but password less login token still works.

    Replace the above login token in the below URL and it logs you in. https://seclearn.myshopify.com/admin?login_token=bd7ffa6c5bf2969fa15753f8fb8cb427-1475133135

Attack scenario:

  1. User gave access to an app.
  2. App used the request and kept an unused login token.
  3. User revoked access to the app.
  4. App can still use the unused login token and access user's data.

The original report as published on HackerOne, by satishb3. 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

Impact

An attacker who obtained an unused passwordless login token before revocation could still log in and access the user's data after the user revoked the app's access.

What the attacker needed

Attacker has access to the app's token; Attacker generates a passwordless login token; User revokes app access; Attacker uses the token before it expires

How it was found

  1. Log into the Shopify iOS app as Alice and obtain the access token.
  2. Send a GraphQL mutation to generate a passwordless login token without using it.
  3. From a desktop browser, log in as Alice and revoke access for the iOS app.
  4. Use the previously generated passwordless login token in the login URL to log in.

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 give an app permission to access your account, you can later revoke that permission. This report shows that a special login link created by the app still worked after revocation, so someone who kept the link could still get in.

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.

More by satishb3

View all

12 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.

Account takeover

The lesson behind this report.

Getting into someone else's account through a flaw in sign-in, password reset, second factor, single sign-on or session handling.