Why API Security Testing Matters
APIs have become the backbone of modern applications. With microservices, mobile apps, and third-party integrations all communicating via APIs, the attack surface has expanded dramatically. The OWASP API Security Top 10 highlights critical vulnerabilities specific to API implementations.
16 Essential API Security Tests
1. BOLA/IDOR Detection (Broken Object Level Authorization)
What it is: BOLA occurs when API endpoints expose object IDs and fail to verify the requesting user's authorization to access that object.
Test Method:
GET /api/users/123/profile -> Success (your ID)
GET /api/users/456/profile -> Should fail, but returns data (BOLA!)
Prevention: Implement object-level authorization checks on every request.
2. JWT Token Attacks
Common Vulnerabilities:
- Algorithm Confusion: Changing RS256 to HS256
- None Algorithm: Setting
alg: noneto bypass verification - Key Brute Force: Cracking weak signing keys
- Claim Manipulation: Modifying payload without detection
Test Method: Decode JWT, modify claims, re-encode with different algorithms.
3. OAuth Abuse
Attack Vectors:
- Redirect URI manipulation
- Scope escalation
- Token leakage via referrer
- CSRF on OAuth flows
Test Method: Analyze OAuth implementation for state parameter, redirect validation.
4. GraphQL Introspection
Risk: Exposed introspection queries reveal entire API schema, including sensitive endpoints.
Test:
{
__schema {
types { name fields { name } }
}
}
Prevention: Disable introspection in production.
5. Mass Assignment
What it is: Attackers add unexpected parameters to modify protected fields.
Example:
POST /api/users
{"name": "John", "role": "admin", "balance": 999999}
Prevention: Use explicit allowlists for accepted parameters.
6. Rate Limiting Bypass
Test Techniques:
- IP rotation
- Header manipulation (X-Forwarded-For)
- Parameter pollution
- Distributed requests
7. API Versioning Vulnerabilities
Risk: Legacy API versions may lack security fixes.
Test: Try /api/v1/ endpoints when /api/v2/ is current.
8. REST Method Tampering
Test: Try unexpected HTTP methods on endpoints:
DELETE /api/users/123
PATCH /api/readonly/resource
9. BFLA (Broken Function Level Authorization)
Risk: Administrative functions accessible to regular users.
Test: Access admin endpoints with non-admin credentials.
10. Excessive Data Exposure
Risk: APIs return more data than needed, leaking sensitive information.
Test: Compare API response against actual UI display needs.
11. API Key Security
Test Points:
- Keys in URLs (logged, cached)
- Missing rate limits per key
- No key rotation
- Overly permissive scopes
12. Webhook Security
Risks:
- SSRF via callback URLs
- Missing signature verification
- Replay attacks
13. GraphQL DoS
Attack Vectors:
- Deep query nesting
- Alias overloading
- Batch query attacks
Prevention: Query depth limiting, query cost analysis.
14. OpenAPI Specification Drift
Test: Compare actual API behavior against documented specification.
15. SOAP Injection
Risk: XML-based attacks on SOAP services.
Test: XXE, XPath injection in SOAP payloads.
16. gRPC Security
Test Points:
- Authentication on streaming endpoints
- Message size limits
- Reflection service exposure
SuperClue API Security Modules
SuperClue includes an API Deep Penetration suite of 16 DAST modules. It covers several of the tests above, including:
- Automated BOLA/IDOR testing
- JWT attack simulation
- GraphQL security analysis
- OAuth flow validation
- Rate limiting assessment
Secure your APIs before attackers find the weaknesses.