Skip to content
Scout 0.3.0: new checks for reachable Go CVEs, IDOR, version disclosure, directory listing, SRI and mixed content.See the catalog

IDOR on the lab

The lab’s /api/users/[id] endpoint serves any user’s object to any caller — a textbook IDOR. Here is how to have Scout confirm it, end to end.

auth.idor proves the bug by comparison: it confirms one identity owns an object, then checks whether a different identity can read the same object. That needs two test identities. Without them the check reports nothing.

Create a config file (for example scout.lab.yaml) with two throwaway accounts, each owning a different user object:

targets:
- name: lab
url: http://localhost:4000
environment: dev
identities:
- name: alice
headers:
Cookie: "session=alice-token"
owns:
- /api/users/1
- name: bob
headers:
Cookie: "session=bob-token"
owns:
- /api/users/2
Terminal window
go run ./cmd/scout scan --config scout.lab.yaml --mode active --env dev

Because the lab enforces no ownership check, Scout confirms that bob can read alice’s object (and vice versa) and reports a High / Confirmed IDOR (CWE-639, OWASP A01:2021). The probe is read-only, compares bodies by hash, and never stores their contents.

If the lab checked ownership on every object access, each identity would get only its own object (or a 403 on the other’s), and Scout would report nothing — exactly the behaviour you want in production.