Attack scenariosAPI security

Other users' data through the API

An API returns a record by its identifier but does not check who is asking. Change the number in the request and you get someone else's data. A script then walks through every number.

Classified as

OWASP API1:2023

Also known as

Broken object level authorization, IDOR

Typical targets

Mobile and single-page application backends

Impact

Mass disclosure of personal and business data

The problem

A request such as GET /api/v1/orders/10452 returns an order. The client is authenticated, but the backend does not check that order 10452 belongs to that client, so a request for 10453 returns another customer's order. One endpoint among hundreds that forgets the ownership check is enough.

Each request is well-formed and authenticated. No WAF can know who owns order 10453: that knowledge lives in the application. The lasting fix is an ownership check in the code. What Mikiri WAF does is narrow what an attacker can send, stop the walk through the identifiers, and keep data from leaving in the response.

Attack request

Request, repeated with the next identifier

GET /api/v1/orders/10453 HTTP/1.1
Host: api.example.com
Authorization: Bearer <token of another customer>
Accept: application/json

What Mikiri WAF detects and limits

What you see in WMC

The records under the host in Attacks show the address, the token-masked request and the run of identifiers in the path. That run points to the endpoint that is missing its ownership check, which is the endpoint to fix first.

Put it in front of your API

Deploy Mikiri WAF on premises in front of your API, load its OpenAPI specification and evaluate it on your own traffic. Evaluation is free, and application traffic stays on premises.

Request an evaluation