Skip to content
Access control Write-up Beginner

How I Exploited Three API Vulnerabilities in a Banking Application

The API trusted client-supplied data: JWT claims for admin status, user IDs in requests, and tokens after logout. An attacker could escalate privileges, access other users' data, and maintain persistent access.

adeolaodunlade Follow

Published on adeolaodunlade.medium.com

Testing BOLA, Broken Authentication, and BOPLA in Damn Vulnerable Bank using Burp Suite

Odunlade Adeola, on adeolaodunlade.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

Root cause

The API did not verify authorization on the server side and relied on client-controlled data such as JWT claims and user IDs.

Impact

An attacker could escalate privileges to admin, access other users' transaction and bill payment data, and maintain persistent access even after logout.

What the attacker needed

Access to the vulnerable application; a valid user account; Burp Suite or similar proxy

The fix

The API should enforce object-level authorization, validate JWT claims server-side, and invalidate tokens on logout.

How it was found

  1. Start the vulnerable bank application locally using Docker.
  2. Configure Burp Suite to intercept browser traffic and log in as a test user.
  3. Decode the JWT and change the is_admin claim from false to true, then resend the request.
  4. Log out and reuse the old JWT in Burp Repeater to see if it is still accepted.
  5. Intercept a request to /transactions/{account} and modify the account number to another user's account.
  6. Modify the user_id parameter in /api/bill-payments/history to other users' IDs and observe successful responses.

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.

This is a practice app built to be insecure. The server believed whatever the browser sent, such as a token saying 'I am an admin' or a user ID in a request. So someone could change those values and see or do things they should not.

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.