IDOR & test identities
IDOR (Insecure Direct Object Reference / broken object-level authorization)
is proven by comparison: one identity owns a private object; a different
identity must not be able to read it. Scout’s auth.idor check needs two
disposable test accounts to make that comparison.
How it works
Section titled “How it works”For each identity’s owned resource, Scout:
- Confirms the owner can actually read it (establishes the baseline).
- Re-requests it as every other identity.
- Flags a confirmed IDOR (High) when another identity receives the byte-identical object.
Configure the identities
Section titled “Configure the identities”Each identity carries the headers that authenticate it and the resources it legitimately owns. In your config file:
identities: - name: alice headers: Cookie: "session=alice-token" owns: - /api/users/1 - name: bob headers: Cookie: "session=bob-token" owns: - /api/users/2Or programmatically when you embed Scout:
scout.WithTestIdentities( core.Identity{ Name: "alice", Headers: map[string]string{"Cookie": "session=alice-token"}, Owns: []string{"/api/users/1"}, }, core.Identity{ Name: "bob", Headers: map[string]string{"Cookie": "session=bob-token"}, Owns: []string{"/api/users/2"}, },)owns entries may be absolute URLs or paths resolved against the target.
Run it
Section titled “Run it”IDOR is an active check:
scout scan --target http://localhost:3000 --mode active --env devWith fewer than two identities configured, auth.idor reports nothing — it is
unconfigured, not a silent pass.
Try it on the lab
Section titled “Try it on the lab”The lab app exposes an IDOR at /api/users/[id]. See
IDOR on the lab for a worked example.