Skip to content
Business logic Write-up Beginner

Business Logic Error: Membeli Kredit di Bawah Minimum Checkout

The checkout session endpoint accepted a modified credit amount, letting a user create a checkout for 100 credits even though the interface enforces a 2,000 credit minimum. An attacker could buy credits below the intended minimum price.

medium.com

Published on medium.com

Saat menguji sebuah aplikasi web pada salah satu program di HackerOne, saya menemukan kerentanan Business Logic Error yang memungkinkan pembelian kredit di bawah batas minimum. Normalnya minimum pembelian adalah 2,000 credits, namun saya berhasil membuat sesi checkout hanya untuk 100 credits.

Robi Mohamad subagja, 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

Root cause

Likely the server trusted the client-supplied credit amount and did not re-check it against the allowed package values or the minimum.

Impact

A user could buy credits below the minimum price, causing financial loss and bypassing the pricing policy; the tester did not complete a real payment.

What the attacker needed

A service account; ability to intercept requests

The fix

The credit amount should be validated on the server so only official package values are accepted.

How it was found

  1. Log in to the service account.
  2. Open the pricing page, choose the 2,000 credit package and start checkout.
  3. Intercept the request that creates the checkout session when continuing to payment.
  4. Change the credits value in the JSON body from 2000 to 100.
  5. Forward the modified request.
  6. Check the JSON response, which contains a checkout session id.

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 a rule that you must buy at least 2,000 credits at a time. The page you see enforces this, but the server behind it did not check the number again. By changing the number in the request before it was sent, the tester got the server to prepare a purchase of only 100 credits.

What is Business logic?

The application works as coded but not as intended: a negative price, a skipped payment step, a limit that can be crossed.

Similar reports

View all

Same bug class and techniques, clearest first.

Business logic flaws

The lesson behind this report.

The application works as coded but not as intended: a negative price, a skipped payment step, a limit that can be crossed.