Skip to content
Access control Write-up Beginner

Hacking Admin Panel & Getting free subscription

The admin panel stored the user's role in a client-side local storage value, so changing it from false to true granted admin access. The attacker could then enable paid services for free and delete other users' subscriptions.

Zeeshan M Follow

Published on z-sec.co

So, a few months back I and Haseeb were hunting on a private program and the program is a services-based company that has paid services only. So the program had very limited assets in scope and most of them were redirected back to the main domain then we used the main domain and checked every functionality we tried…

Zeeshan M., on z-sec.co

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 application trusted a client-side local storage value for authorisation decisions instead of enforcing roles on the server.

Impact

An attacker could escalate to admin, enable paid services for free, and delete other users' subscriptions.

What the attacker needed

A free account on the developer portal; access to the admin panel URL; ability to edit browser local storage

How it was found

  1. Find a developer portal and register an account via its API.
  2. Discover an admin panel that shares the same JWT authorisation.
  3. Open the admin panel and inspect local storage to find a role parameter.
  4. Change the role value from false to true and refresh the page.
  5. Access admin functions such as enabling paid services or deleting subscriptions.

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 sometimes keeps information about you in your browser, such as whether you are an admin. If the website trusts that information without checking with the server, you can change it yourself. Here, the attacker changed a stored value from 'not admin' to 'admin' and the site let them in.

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.

More by Zeeshan M

View all

2 more disclosed reports, best first.

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.