Security

Business Logic Vulnerabilities: 9 Flaws a Standard Scan Can Miss (With Pentest Examples)

ShamDecember 1, 20268 min read

Published by OraSec

Sample checkout request with the price changed from 249.00 to 0.01, confirmed as a $0.01 order: a business logic vulnerability.

What is a business logic vulnerability?

A shopper adds a $249 item to the cart, changes one number in the checkout request, and pays $0.01. The server accepts the order and sends a confirmation.

https://www.youtube.com/shorts/8nEgePe7HYo

Simulated demo in a sample shop, not a real customer incident. Watch on YouTube

That is a business logic vulnerability. PortSwigger defines business logic vulnerabilities as flaws in the design and implementation of an application that let an attacker cause unintended behavior. Nothing in the request is malformed. The attacker uses a real feature in a way the developers never planned for.

Most logic flaws start with an assumption nobody wrote down. Four come up again and again:

  • Users only send the prices the page shows them.
  • Users follow the steps in order.
  • Users apply a coupon once.
  • Users only ask for their own invoices.

These flaws matter because they sit on the flows that move money, data and access: checkout, refunds, sign-up, roles and exports. Abuse can look like normal traffic. Each request is valid on its own, so it often passes without an error or an alert.

This guide explains why a standard scan can miss these flaws, walks through nine that pentesters find, and shows how testers look for them and what a good report should prove.

Why a standard scan can miss business logic flaws

Automated scanners do a lot well. They match known vulnerability patterns, spot revealing error messages, flag outdated software versions and report missing security headers. They cover thousands of pages faster than any person can.

Logic flaws often look like success. A $0.01 order returns a normal response and a confirmation page, just like a real one. To call it a bug, a tool would need to know the business rule: the price must come from the catalog, not from the client. PortSwigger notes that this makes logic flaws difficult to detect with automated vulnerability scanners.

A scan also rarely has the context that logic testing needs:

  • Several accounts, in different roles and tenants, to compare what each one can reach.
  • The order of steps in a flow, and which steps can be skipped or repeated.
  • Parallel requests timed to hit the same record at the same moment.
  • A definition of harm: what counts as a lost sale, a leaked file or an unpaid seat.

OWASP treats many of these as design problems. The OWASP Top 10:2025 places them under A06:2025 Insecure Design, which covers flaws in an application's business logic. For APIs, the OWASP API Security Top 10 has a dedicated entry, API6:2023 Unrestricted Access to Sensitive Business Flows.

Aspect

A standard scan covers well

Logic testing adds

Inputs

Known injection and scripting payloads

Valid values the business should reject, such as a price of 0.01

Accounts

One user session, or none

Two or more accounts in different roles and tenants

Flow

Single pages and endpoints

The order of steps, plus skipped and repeated steps

Timing

Each request checked on its own

Many requests sent at once against the same limit

Use scanners for breadth and regular coverage. Use expert testing for the rules only your business has. Our guide to penetration testing vs vulnerability scanning explains how the two fit together.

9 business logic flaws pentesters find

All examples below are simulated, from sample apps. Each flaw has a one-line definition, an example and a fix.

1. Price and Quantity Tampering

The server trusts a price or quantity that the client sends.

Example: The checkout request in a sample shop carried "price": 249.00. Changing it to 0.01 created a paid order for one cent. The same endpoint accepted a quantity of -1, which took money off the cart total, 0.5, which halved the line price, and 99999, which went past stock with no check.

Fix: The server calculates the price from trusted product data and ignores any price in the request. It checks every quantity: a whole number, above zero, and within stock and per-order limits.

2. Promo and Discount Stacking

Discounts combine or repeat in ways the business never intended.

Example: A single-use code was applied twice by resending the same "apply coupon" request before the order closed. In a second test, a 20% code stacked on top of a sale price and then on store credit, pushing the item well below cost.

Fix: Write server-side rules for which discounts can combine, and enforce them when the total is calculated. Mark a single-use code as used in the same step that applies it, so a second request finds it already spent.

3. Race Conditions on Limits

Parallel requests slip past a limit that holds when requests arrive one at a time.

Example: A $50 gift card in a sample app received 20 redemption requests at once. Several read the balance before the first one updated it, so the card paid out more than its value. PortSwigger calls this a limit overrun race condition and lists gift card redemption as a typical case.

Fix: Check and update in one atomic step, using a row lock or a conditional update such as UPDATE cards SET balance = balance - 50 WHERE id = ? AND balance >= 50, and reject the redemption if no row was updated. Add a unique constraint so a single-use redemption can only be recorded once. A plain database transaction or idempotency keys alone are not enough. The first can still let two requests read the same balance, and the second only stops retries of the same request.

4. Workflow Step-Skipping

The app assumes users move through each step in order.

Example: A sample checkout ran cart, shipping, payment, then confirmation. Calling the confirmation endpoint straight after shipping marked the order as paid, with no payment taken.

Fix: The server tracks each order's state and only allows valid next steps. An order is marked paid only after the payment provider confirms it server-side, for example through a verified webhook, never because the browser reached the success page.

5. Cross-Tenant IDOR/BOLA

One customer reaches another customer's objects by changing an ID.

Example: In a sample SaaS app, testers used two customer accounts in two tenants and swapped invoice, user and export IDs on every endpoint and every method. Most requests were blocked. One export endpoint returned the other customer's file. The export IDs were UUIDs, which made them hard to guess but did nothing to stop the request. UUIDs are not authorization.

Fix: Check ownership of every object on the server, on every request, including files, exports and webhooks. The OWASP API list calls this API1:2023 Broken Object Level Authorization, and our explainer on what BOLA is covers the pattern in depth.

Related: One IDOR Away From Exposing 2.7 Million Customer Records

6. Role-Parameter Escalation

The server accepts fields or functions that the user's role should never reach.

Example: Adding "role": "admin" or "plan": "enterprise" to a normal profile update saved both values in a sample app. A regular user could also call an admin endpoint directly. The interface hid the button, but the server never checked the role.

Fix: Allow-list the fields each role can change and drop everything else. Check permissions for every function on the server, not in the interface. These map to API3:2023 Broken Object Property Level Authorization and API5:2023 Broken Function Level Authorization.

Related: Broken Access Control: 6 Real Examples Found in Pentests

7. Refund Abuse

Refund logic pays out more than the customer paid.

Example: In a sample store, each partial refund on a $120 order was checked against the original total, not against what had already been refunded. Three partial refunds of $60 added up to $180. The same order could also be refunded to store credit and to the card, because the two refund paths did not know about each other.

Fix: Tie each refund to the original payment. Cap it at what is still refundable after earlier refunds. Lock the order while a refund runs, so a second refund through another path waits and sees the updated balance.

8. OTP and Enumeration Without Rate Limits

Login and sign-up flows allow unlimited guesses or reveal which accounts exist.

Example: A 6-digit code has 1 million possible values. With no attempt limit and a code that stays valid, a script sending 100 guesses a second can try all of them in under three hours. Separately, the sample sign-up form replied "already registered" for existing emails, confirming which addresses had accounts.

Fix: Limit attempts per code and per account, with IP limits only as an extra layer, since attackers rotate IP addresses. Cancel the code after a few failures, keep expiry short, and give the same reply for every email. Our MFA security testing methodology covers the wider set of checks.

9. Booking and Inventory Hoarding

Automated users hold scarce inventory without paying for it.

Example: In a sample travel app, a script held every seat on a flight without paying. Real customers saw the flight as sold out until the holds expired, and then the script held the seats again.

Fix: Cap holds per account and device, keep hold times short, and require a card authorization for large holds. Add bot detection to the flow. OWASP covers this pattern in API6:2023, with an example of one user booking 90% of the seats on a flight.

How expert testers find business logic flaws

OWASP's Web Security Testing Guide describes business logic testing as largely manual work that depends on the skill and creativity of the tester. A typical approach follows six steps:

  1. Map the key flows. List the flows that move money, data or access, and the rules each one depends on.
  2. Walk them through a proxy. Run each flow normally through an intercepting proxy such as Burp Suite and record every request.
  3. Turn each rule into abuse cases. "One coupon per order" becomes: apply it twice, apply it in parallel, and apply it after checkout.
  4. Test with two or more accounts in two tenants. Swap IDs, roles and tokens between them on every endpoint.
  5. Send requests in parallel. Fire the same request many times at once to find race conditions on limits.
  6. Stop once the impact is proven. Use test accounts and test data only, and go no further than the proof requires.

OraSec's web application security testing includes these steps.

What to Give Your Testers

  • Accounts for each role in two tenants.
  • The 3 to 5 flows that matter most.
  • The rules for each flow, such as pricing, discount, refund and role rules.
  • Recent changes to payments, pricing, sign-up or roles.

For mobile backends and partner integrations, the same flows are tested at the endpoint level through API security testing.

What a pentest report should prove for each logic flaw

A logic finding helps only if developers can reproduce it and leaders can see why it matters. Each finding should include:

  • The broken rule in plain words, such as "a coupon can be used once per account."
  • Proof: the original request, the changed request and the server response.
  • Steps to reproduce that a developer can follow without the tester.
  • Business impact in terms of money, data or access.
  • Why this severity, so the rating can be checked rather than taken on trust.
  • Root cause and fix, aimed at the missing server-side check.
  • Retest results that show the fix holds.

You can see this structure in our sample pentest report.

FAQ

What is an example of a business logic vulnerability?

A simulated checkout where changing the price from $249.00 to $0.01 in the request created a paid order. The server trusted a price sent by the client.

Can automated scanners find business logic vulnerabilities?

Sometimes, in simple cases. A standard scan can miss them, though, because the requests look valid and the tool usually doesn't know your business rules.

Are business logic vulnerabilities in the OWASP Top 10?

Yes. They fall under A06:2025 Insecure Design, and many related access flaws sit under A01:2025 Broken Access Control. For APIs, see API6:2023.

How do you prevent business logic vulnerabilities?

Write the business rules down, enforce them on the server, add abuse cases to QA testing, and test again after major changes to key flows.

How often should you test for business logic flaws?

At least once a year and after major changes to payments, pricing, sign-up or roles. Higher-risk teams often test more frequently. See how often you should do a pentest.

Test the logic, not just the code

Does your checkout, sign-up, refund or API flow trust the wrong thing? OraSec's web application testing includes a business logic assessment, with findings mapped to the OWASP Top 10 and ASVS and fixes written for developers.

Request a pentest

About the author

Muhammad Tayab Bashir is a Penetration Testing Specialist at OraSec (PNPT, MCRTA) with 3 years of hands-on experience testing web apps, APIs and cloud for business logic and access-control flaws.

Sources

Explore related services

Need hands-on help? Our security testing services put this research into practice.

Binance hack 2026

Binance Hack: What We Know About the $6.3 Billion Hot Wallet Theft

On October 29, 2026, attackers drained Binance hot wallets across multiple blockchains in what blockchain analytics firms call the largest crypto theft on record. Binance puts the impact at about $6.3 billion, with roughly $3 billion frozen, and says early findings point to a possibly compromised engineer's laptop, with no evidence of leaked private keys so far. Here's what happened, what's still unconfirmed, and what to check in your own environment. What happened at Binance? Attackers drain

·6 min read
Oracle E-Business Suite RCE (CVE-2026-101767): What to Do Now

Oracle E-Business Suite RCE (CVE-2026-101767): What to Do Now

CVE-2026-101767 is a critical flaw in Oracle E-Business Suite (EBS), rated CVSS 9.8. It lets an unauthenticated attacker send a crafted web request that triggers SQL injection and can be chained into full remote code execution. Oracle patched it in its October 20, 2026 Critical Patch Update, and attackers were already probing for it a week later. If you run EBS, this one needs attention now. What is CVE-2026-101767? An unauthenticated SQL injection in Oracle E-Business Suite that can be chain

·5 min read
Black October 2026: Every Major Vulnerability and Breach

Black October 2026: Every Major Vulnerability and Breach

October 2026 brought so many critical flaws and breaches at once that the security community started calling it "Black October." Two unauthenticated remote code execution bugs in PHP core, a CVSS 10.0 flaw in GitLab reaching back twelve years, an exploited SQL injection in Oracle E-Business Suite, Microsoft's largest-ever Patch Tuesday, and a ~20 million patient breach at Oracle Health all landed in the same few weeks. This roundup covers what broke, who's affected, and what to fix first. What

·6 min read