Skip to content
Account takeover Write-up Advanced

How I Turned a Dark Web Sketch into a $ Bug Bounty Payday ️‍�

A leaked internal API endpoint and a partial JWT token were found on a dark web forum. The attacker discovered the endpoint was publicly accessible and exploited a JWT algorithm confusion flaw to forge an admin token, then accessed the endpoint to export sensitive user data.

iski Follow

Published on infosecwriteups.com

Free link 🎈

Iski, on infosecwriteups.com

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 server accepted a public key as an HMAC secret for JWT verification, enabling algorithm confusion, and the internal admin endpoint was exposed without proper access controls.

Impact

The attacker could access an internal admin endpoint and export thousands of user records containing PII and financial information.

What the attacker needed

Leaked internal endpoint and token; free account on main app; publicly accessible JWKS

The fix

The server should not accept a public key as an HMAC secret and should enforce proper algorithm validation; the internal endpoint should not be publicly accessible.

How it was found

  1. Found a leaked internal API endpoint and partial JWT token on a dark web forum.
  2. Used subdomain enumeration tools to discover the live internal API endpoint.
  3. Created a free account and captured a low-privilege JWT token.
  4. Analyzed the token and identified it used HS256 algorithm.
  5. Located the public JWKS at auth.securebank.com.
  6. Forged an admin JWT using the public key as HMAC secret and accessed the data export endpoint.

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.

The company had an internal admin API that was accidentally exposed to the internet. The login system used a type of token that could be forged if the server's public key was known, allowing the attacker to pretend to be an administrator and download private user information.

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 iski

View all

186 more disclosed reports, best first.

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.