Instead of each developer writing their own authorization check on every endpoint, implement a centralized authorization layer — a single piece of code or policy that all requests pass through before reaching the data.
This can be an API gateway policy, a middleware function, or a dedicated authorization service. The key is: one place enforces the rule, not hundreds of individual endpoints.
Imagine a hotel. Instead of each room having its own security system that every staff member has to remember to set — there's one central front desk that controls access to every room. Miss the front desk and you don't get in, period.
Centralized authorization is the front desk. A developer adding a new endpoint doesn't need to remember to add a check — the check happens automatically before they even get to the endpoint.
A centralized layer is only as good as its rules. If the policy itself has gaps — or if some endpoints bypass the layer entirely — protection fails. The policy needs to be tested (MIT 04) just like everything else.
Ask your QA team whether your tests ever try to access one user’s data while logged in as a different user. If that test doesn’t exist, BOLA is essentially untested in your system.