In-depth lesson · IDOR
Typical fixes
Every point the IDOR reports back under this heading, best-backed first, each with the reports it is seen in.
-
Avoid AES-ECB with a hardcoded key for password encryption.
Seen in 1 report
-
Verify the caller owns or is entitled to the source attachment before cloning it.
-
Apply authorisation checks to hidden endpoints regardless of the HTTP method used to reach them.
Seen in 1 report
-
Enforce the same authorisation checks across all HTTP methods on an endpoint.
Seen in 1 report
-
Bind refresh tokens to the authenticated user or session and avoid long-lived static refresh tokens.
Seen in 1 report
-
Accept only an allowlist of fields from the request body rather than applying every submitted field to the order.
Seen in 1 report
-
Validate step values against an allowed range and match the token owner to the user_id in the path.
Seen in 1 report
-
Require completed OTP verification rather than authorising on possession of an application token alone.
-
Validate and sanitise URL fields so that javascript: schemes cannot be stored and executed.
Seen in 1 report
-
Enforce the name confirmation step server-side and check that the project code matches the confirmed project.
Seen in 1 report
-
Bind cookie and nonce values to the session and validate their actual values, not just their length.
Seen in 1 report
-
Retire legacy API versions or bring them up to the same authorisation and encryption standards.
Seen in 1 report
-
Do not run user-triggered functions with a role that bypasses row-level security, and validate destination paths.
Seen in 1 report
-
Disable public listing on storage buckets and avoid predictable ids for paid files.
Seen in 1 report
-
Parameterise database queries and check authorisation on the application number.
-
Compare the supplied room id with the file's owning room before serving the file.
Seen in 1 report
-
Re-check permissions against the repository named in the request body, not only the one in the URL.
-
Replace unconditional permission callbacks with real authentication and ownership checks.
-
URL-encode user input before placing it into internal query strings.
Seen in 1 report
-
Carry field-level and row-level access rules over to synced copies of data.
Seen in 1 report
-
Include the resource identifier in the authorisation cache key.
Seen in 1 report
-
Resolve and normalise the storage key before checking ownership, and sign only the value that was checked.
Seen in 1 report
-
Normalise paths before validation and use the same value for the authorisation check and the lookup.
Seen in 1 report
-
Apply per-key ownership checks to every element of an array parameter downstream.
Seen in 1 report
-
Authorise each operation in a batched GraphQL request individually rather than setting a request-wide flag.
Seen in 1 report
-
Do not branch authorisation on the client-supplied operation type; apply ownership checks to every operation.
-
Set default permission classes and declare permission classes on every view.
-
Pass the object ID into the permission callback and check per-object capability.
Seen in 1 report
-
Prove domain ownership and enforce global uniqueness before binding a domain to a workspace.
-
Tighten storage security rules so listing and reads require authentication and ownership.
Seen in 1 report
-
Bind each OTP to the specific verification resource and enforce country restrictions server-side.
Seen in 1 report
-
Keep encryption keys server-side and never expose them to the client.
-
Require authentication and ownership before serving uploaded images.
-
Require authentication and an ownership check before returning order details.
Seen in 1 report
-
Isolate tenant state in internal services so one account's container cannot read another's writes.