← All perspectives

Perspective / Data & platform engineering

Tenant isolation and enterprise authorisation: proving where access stops

Enterprise access control depends on enforceable boundaries across APIs, databases, files and background jobs. A worked authorisation model shows how to turn tenant isolation into architecture, tests and reviewable evidence.

10 min readReviewed

Separate illuminated archive rooms divided by solid walls and independent access routes.
Conceptual editorial image.

Tenant isolation needs to be designed as an end-to-end property of a platform. A successful login establishes identity; the system must still determine which organisation, resources and operations that identity can access throughout a transaction. For commercial platforms, the important question is whether those decisions remain correct through exports, scheduled jobs, caches and support workflows. An explicit isolation model, backed by negative tests, gives executives a stronger basis for evaluating risk than a feature list containing single sign-on and user roles.

The executive view

  • Define tenant boundaries across every resource and execution path before selecting an isolation mechanism.
  • Evaluate object-level permissions through trusted context and explicit policies, including asynchronous work.
  • Use negative tests and reviewable evidence to demonstrate the behaviour of implemented controls.
01

Define the boundary before choosing the mechanism

An organisation can have several legitimate boundaries: a legal customer, a subsidiary, a project or an account within a wider customer group. Calling all of them a tenant makes implementation ambiguous. Start with a domain diagram that distinguishes the contracting customer from the objects it owns and any relationships that permit sharing.

AWS treats isolation as a separate architectural concern from authentication and authorisation, with enforcement extending beyond the initial entry point. That is an established principle rather than a new product feature. Its tenant isolation guidance provides a useful foundation.

A practical boundary statement should identify protected resources, permitted cross-boundary operations and the authority that approves them. It should also state whether support personnel, system jobs and customer administrators follow different rules. Unwritten exceptions tend to become permanent access paths.

Separate customer-managed sharing from platform administration. A customer may legitimately invite a supplier into one project without sharing its full order book. Represent the relationship and permitted operations directly rather than granting membership of the entire tenant as a shortcut. Shared resources need an accountable owner and an explicit rule for revoking access when the commercial relationship ends.

Include the control plane in the boundary model. Provisioning, billing support, data migration and tenant deletion often run with broader privileges than ordinary requests. Inventory those paths and decide how their scope is approved and checked. A secure customer-facing API does not compensate for an administrative script that accepts any tenant identifier and exports its data. The isolation promise must describe the whole service that customers are buying.

02

Establish trusted context at each entry point

Consider an illustrative procurement portal in which two customers maintain separate suppliers, orders and documents. A browser may request an order using an identifier and a selected organisation. Neither value should establish the caller’s entitlement by itself.

At the application boundary, verify the authenticated principal, resolve current membership and derive the active tenant from trusted records. Carry a constrained execution context into downstream operations. If an endpoint accepts a tenant selector, validate that selection before using it. A background service needs its own identity and scope rather than an assumed human session.

Context should be explicit enough to inspect during review: principal, active tenant, permitted operation and relevant relationship. Avoid passing a large mutable user object through every layer. An immutable, narrowly defined context makes omissions easier to detect and prevents an unrelated request field becoming an accidental source of authority.

Consider tenant switching as a state transition. When a user belongs to two organisations, changing the selected tenant should invalidate or segregate cached queries, downloads and outstanding form state. A correct server-side check can still coexist with a confusing browser that displays information from the previous context. Make the active organisation visible in consequential workflows and confirm it again before sensitive actions.

Resolve the authority of service-to-service calls explicitly. A signed internal token demonstrates who issued a request; it does not automatically establish which customer's resources the caller may use. Constrain its audience, scope and lifetime, and validate the tenant-resource relationship at the receiving service. Avoid trusting an arbitrary tenant header merely because the request originated from the internal network.

03

Separate policy decisions from scattered conditions

A role name alone rarely captures enterprise permissions. A buyer may view an order but approve it only below a spending limit; a project manager may administer one project without administering the entire organisation. Model permission as a decision involving an actor, operation, resource and context.

Create a policy catalogue with stable identifiers such as order.read, order.approve and document.export. Specify default behaviour, relationship rules and exception handling. Keep policy evaluation close to the protected operation, while ensuring every public path reaches it.

OWASP’s object-level authorisation guidance explains why unpredictable identifiers do not remove the need for access checks. In the example portal, changing an order ID must never be sufficient to reach another customer’s record. Test that requirement directly rather than relying on assumptions about how difficult an identifier would be to guess.

Keep approval policy separate from identity membership. A person may belong to an organisation while being prohibited from approving their own request. Financial limits may depend on currency, aggregated spend or a project budget, so the policy's input data and freshness requirements must be defined. A role called manager cannot express those conditions without additional decision logic.

A central policy service can improve consistency, but it introduces a dependency that needs failure behaviour and version management. Decide which actions fail closed when the evaluator is unavailable and which read-only experiences can continue with previously authorised information. Record the policy version used for a consequential decision without treating that audit field as permission to reuse an obsolete approval indefinitely. Permission changes should have a defined propagation expectation.

04

Enforce isolation across storage and delivery

The resource inventory must extend beyond database rows. A search index, object-storage key, download URL, cache entry and analytics export can all expose information independently of the screen that originally displayed it.

For the illustrative portal, define how tenant scope enters each query and how the platform verifies the ownership of referenced objects. Evaluate database enforcement where appropriate, but document the privileged paths that can bypass it. Cache keys should include the dimensions required to distinguish authorised results. A shared cache entry for an order summary can undermine otherwise correct query logic.

Files deserve a separate decision: possession of a URL may confer access for its lifetime. Choose expiry, revocation and download checks according to sensitivity and workflow. The architecture review should show the complete route from policy decision to delivered bytes, including previews and generated archives.

Where PostgreSQL row-level security is used, examine the database roles actually used by the application and operational tooling. The PostgreSQL documentation explains that superusers and roles with BYPASSRLS bypass the policy system, and that table owners normally do as well. A policy attached to the right table is insufficient if ordinary application traffic uses an inappropriate privileged role.

Connection pooling creates another implementation obligation: tenant context must not leak between requests. Establish context within the intended transaction boundary and test reuse of the same connection for different tenants. Review joins, materialised data, search results and bulk operations independently. Database policy can provide defence in depth, but it does not automatically cover a file copied into object storage or a response already placed in a shared cache.

05

Preserve authority through asynchronous work

Bulk exports and scheduled jobs often outlive the request that created them. Decide whether the job captures an approved scope at creation or re-evaluates permission at execution. Both models require deliberate treatment of membership changes, cancelled requests and expired access.

An export job record might contain a request identifier, initiating principal, tenant, approved filters, policy version and expiry. A worker should load that record from a trusted store and verify the relationships it relies on. Treat a queue message as a pointer to authorised work, rather than an unrestricted instruction to fetch arbitrary records.

Support access requires comparable discipline. Define who may initiate it, what justification is recorded, how long it lasts and which operations are prohibited. A visible audit trail is useful only if its events correspond to decisions the system actually enforces. Recording broad administrator access does not make that access appropriately scoped.

An asynchronous permission model should specify revocation. If a user starts a large export and then loses access, decide whether the job is cancelled, its output is withheld or a previously approved snapshot remains available under a documented rule. Protect both production and download of the artefact. Cancelling the worker is insufficient if a completed archive can still be retrieved through an old link.

Use bounded support sessions rather than permanent customer impersonation where the operating model permits. Record the justification, approver, expiry and resources accessible during the session, and distinguish support actions from the customer's own actions. Test emergency access as an exceptional workflow with its own constraints. Broad access may sometimes be operationally necessary, but its necessity should be demonstrated rather than inherited from a convenient administrator role.

06

Build a test matrix around forbidden outcomes

A meaningful isolation suite deliberately attempts operations that should fail. Use a small fixture with two tenants, different roles, a shared project and revoked membership. Verify response behaviour and side effects: a rejected write should not alter a record or leave a downloadable artefact.

ScenarioRequired evidence
Tenant A requests Tenant B’s orderNo protected data or existence detail outside the agreed policy
Viewer attempts approvalNo state transition or approval event
Revoked user starts an exportRequest rejected under the current membership rule
Worker receives a modified resource referenceScope validation fails before retrieval
Cached response follows a tenant switchPreviously authorised data is not reused incorrectly

Run equivalent checks through direct API calls, not only the user interface. Add tests for new resource types when they enter the platform. A policy change should identify the affected tests and expected behaviour before implementation begins.

Test compound operations, not just individual endpoints. An attacker may read a permitted project and substitute another tenant's document identifier into an export request. The application must validate the relationship among the supplied objects, not merely confirm that each identifier exists. Repeat the test through bulk selection, pagination, filtering and generated report paths.

Add negative checks for observable side effects. A rejected request should not create a job, send a notification containing protected information or leave a partial archive. Inspect access logs and event records as well as the response. For timing-sensitive membership changes, state the revocation guarantee the system actually supports and test against it. Avoid describing an eventually updated permission cache as immediate revocation when there is a known window.

07

Choose the operating model with its full cost visible

Dedicated databases or infrastructure can simplify some boundaries while increasing provisioning, migration and operational overhead. Shared resources can support efficient delivery while demanding stronger policy consistency and isolation testing. The appropriate choice follows the customer’s requirements, data sensitivity and operational capacity.

An executive review pack should contain the boundary diagram, policy catalogue, enforcement inventory, test results and an exception register with named ownership. Distinguish planned controls from verified implementation. Record where independent security assessment is required and what its scope covers.

The commercial decision is therefore more precise than choosing between shared and dedicated hosting. It is a decision about which boundaries the product promises, how those promises are enforced and what evidence will remain available as the platform changes. That evidence should evolve with new endpoints, integrations and operating procedures, rather than being assembled only for the next tender.

Compare isolation models through operating scenarios. Dedicated databases may reduce some cross-tenant query risks but increase the number of migrations, backup checks and recovery exercises. Shared storage can simplify fleet operation while making query scoping and policy regression more consequential. Neither choice removes the need to authorise users and administrators correctly.

Include growth and exceptional customers in the cost model. A customer requesting dedicated storage may require a distinct provisioning and support path, not merely another configuration flag. Ask whether the organisation can patch, restore and verify every promised variant. The commercial review should connect contractual isolation language to a tested technical model and an achievable operating process. An assurance questionnaire is stronger when its answers point to current evidence and clearly scoped limitations.

08

An isolation assurance pack for enterprise procurement

Procurement responses should describe the boundary actually implemented, not simply list security products. A concise evidence pack can contain the tenant model, resource inventory, policy catalogue, privileged-access process and current negative-test results. Link each material promise to an owner and a defined review trigger.

For a new resource type, ask how tenant ownership is represented, how the request obtains trusted context and where the final bytes or state transition are protected. Then ask how the design behaves during permission changes, retries and support intervention. These questions expose gaps that a high-level diagram can conceal.

Scope independent review to the implemented service and its administrative paths. A penetration test can add valuable evidence, but it is a point-in-time assessment with a defined scope. Keep the regular isolation suite and operational controls active as the product changes. The objective is a boundary the organisation can continuously explain, enforce and verify.

Further questions

Questions this raises

Is single sign-on enough to establish tenant isolation?

No. Single sign-on identifies the caller. The application still needs to enforce which tenant, objects and operations that caller may access, including work performed by services and background jobs.

Does every tenant need a separate database?

That depends on contractual requirements, sensitivity, architecture and operating capacity. Dedicated and shared models have different enforcement and operational costs; the decision needs explicit requirements and tested controls.

What should a tenant isolation test verify?

It should attempt forbidden reads, writes, downloads and jobs across tenant and role boundaries, checking both returned information and side effects. Interface visibility alone is insufficient evidence.

References

Sources & further reading

  1. AWS SaaS Tenant Isolation Strategies 1 August 2020
  2. AWS: The isolation mindset 1 August 2020
  3. OWASP API1:2023 Broken Object Level Authorization 2023 edition
  4. PostgreSQL: Row Security Policies

Connected capabilities

Software & CRMStrategy & digital transformation

From thinking to doing

What could this mean
for your business?

Your next chapter

What could your
business do better?

Tell us where you want to go, what’s getting in the way, or what you need to deliver. We’ll start there.

Start a conversation

Start a conversation

Tell us what
you have in mind.

Interactive preview. Your information stays in this page and is not sent.