Business Logic Vulnerabilities

Flaws where every request is well-formed and the server does exactly what it is asked, but it should never have honoured the request, because a business rule (price, quota, order of steps, entitlement) was assumed rather than enforced. CWE-840.

What it is

  • Business logic is code that models real-world business decisions. Testing it means challenging the developer’s assumptions about how people use the application, not finding data-handling oversights. Because it depends on what the application is for, scanners can’t find it (Web AppSec Interview Questions).
  • These bugs live in the gap between what the application is supposed to allow and what it actually enforces. Nothing is malformed, so there’s no signature (Red Agent: one boolean).
  • The trust boundary that breaks is client-side intent vs. server-side invariant. The server trusts something the client controls: a total, a flag, the order of steps, the count of redemptions. It also assumes API consumers follow the documented directions (API Exploitation for Bug Bounty).
  • Broken access control and BOLA are themselves described as logic flaws, a semantic gap that SAST and DAST can’t close (Why BAC dominates). The two classes overlap heavily, see Broken Access Control.
  • OWASP coverage: WSTG-BUSL in the web testing guide (WSTG methodology). In the API Top 10, API6:2023 Unrestricted Access to Sensitive Business Flows was added in 2023 and can exist without any implementation bug (OWASP API Security Project, Salt: API Top 10 explained). The 2023 update is read as a shift toward business-logic and workflow abuse (Wiz: API Top 10).

Why it matters

How it works

Four families cover most cases. Each has its own page:

FamilyInvariant brokenPage
Value tamperingServer derives price and total, and bounds quantity and amountPrice and Quantity Manipulation
Flow tamperingSteps happen in order and state matches the stepWorkflow and State Bypass
Quota tamperingIncentives are redeemed once, within value, by real usersCoupon and Reward Abuse
Entitlement tamperingPlan, credit and quota checked on the server per requestPaywall and Entitlement Bypass

Cross-cutting enablers, owned elsewhere:

Where to find it

How to test

Methodology:

  1. Learn the business. Know what the app sells, gates and protects, and read the developer documentation for stated rules and role matrices (Data deletion via subdomain sync, API Exploitation for Bug Bounty).
  2. Use the app as a normal user through a proxy and capture every request in each flow (Bug Bounty 101).
  3. Write down the invariants each flow should preserve, then test whether they survive concurrent requests or an alternate path (Bitvulnex).
  4. Attack the assumptions: what if this happens twice at once, out of order, from another channel, or after the state changed (Backend Mastery)? “They want me to do this, so what if I do the opposite?” (Interview with Stefan Goossens).
  5. Mine the client for parameters, routes and flags the UI never sends (Red Agent: one boolean, JavaScript Analysis).
  6. Verify the persisted effect (order total, ledger, account state), not the UI or a 200 (Payment extension API).
  7. Report in business terms: money, records and workflows affected (The $0 IDOR worth a $12,500 P1).

Checklist (Bug Bounty Hunting in 2026, Common Bug Bounty Vulnerabilities, API pentest checklist, Mastery Hunt):

  • Monetary and count fields: zero, negative, fractional, oversized, off-menu values
  • Is any total or price accepted from the client?
  • Can steps (verification, 2FA, payment) be skipped or reordered?
  • Can flow-binding attributes change after a step is issued?
  • Are single-use items (coupon, gift card, token) redeemable concurrently or across channels?
  • Do discounts stack?
  • Is each plan, credit and quota limit enforced by the API for a free account with no UI tampering?
  • Is every action permitted by the same role matrix on every surface?
  • Do role or ownership changes take effect immediately (API Pentesting guide)?
  • Can sensitive flows be automated at volume (API6)?

Exploitation and escalation

Bypassing defenses

Real-world cases

Prevention

  • Server owns every business value: recompute prices and totals, bound numbers, and use overflow-safe arithmetic (Integer overflow, ₹0).
  • Server owns entitlement and eligibility, per request and per record. Never infer either from what the client sends (Red Agent: one boolean, Payment extension API).
  • Explicit state machines: server-held flow state, single-purpose step tokens, and step tokens (HMAC over flow state) for sensitive flows (OWASP API Top 10 guide with tests).
  • Atomic, idempotent money operations: idempotency keys, conditional updates, velocity rules per user, device and ASN, and quota-limited async jobs for bulk operations (OWASP API Top 10 guide with tests).
  • Centralised authorization (a policy decision point) so rules aren’t duplicated per handler or channel (Why BAC dominates, Authorization Policy Engines).
  • Regression tests for abuse cases: unauthorized references, ineligible accounts, stale states, duplicate submissions. Add audit logs that record actor, target and state change (Payment extension API).
  • Manual testing in scope. Scanners are weak at business logic, so API pentests need it as an explicit scope item (Preparing for an API pentest).

Tools

Sub-pages

Race Conditions · Mass Assignment · Second-Order and Multi-Step IDOR · Broken Access Control · MFA Bypass · Password Reset Vulnerabilities · OWASP API Security Top 10 · API Rate Limiting · Vulnerability Chaining · Bug Bounty Methodology

Sources