Skip to content
Access control Write-up Beginner

Logic Over Locks: How I Unlocked Premium Features on a Free Account

A premium feature was protected only by a UI paywall, while the backend accepted requests from free accounts without checking subscription status. An attacker could replay a captured premium request with a free session and user ID to unlock the feature without paying.

amendahunt Follow

Published on medium.com

While testing a web app, I found a business logic flaw: a solid UI paywall protecting a premium feature, but a backend that blindly trusted incoming requests. Here is how a few minutes with Burp Suite unlocked the pro tier on a free account

amen, on medium.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

Impact

Any free user could bypass the paywall indefinitely, causing revenue loss and feature devaluation.

What the attacker needed

A free account; a pro account to capture request; Burp Suite or similar proxy

The fix

The backend should enforce authorization at the resolver level by checking the user's subscription status in the database before executing any sensitive mutation.

How it was found

  1. Capture a request to create premium content from a Pro account.
  2. Switch to a Free account session in the browser.
  3. Send the captured request to Burp Repeater.
  4. Replace the Pro session cookie with the Free session cookie.
  5. Replace the Pro user ID with the Free user ID.
  6. Send the modified request and observe a 200 OK response.

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.

A website has two parts: what you see (the user interface) and the server that does the work. Here, the 'upgrade to pro' popup only stopped you in the interface, but the server would still do the premium action if you asked it directly. By changing the session cookie and user ID in a saved request, the tester made the server think a free user was allowed to create premium content.

What is Access control?

A user can do something their role should not allow: reach an admin function, act on a feature they have not paid for, or skip a permission check. IDOR is the special case where the object belongs to someone else.

Similar reports

View all

Same bug class and techniques, clearest first.

Broken access control

The lesson behind this report.

A user can do something their role should not allow: reach an admin function, act on a feature they have not paid for, or skip a permission check. IDOR is the special case where the object belongs to someone else.