Skip to content

Tenant Isolation, Physical and Logical

Learning objectives

By the end of this module you should be able to:

  • Distinguish API-layer filtering from storage-layer partitioning and say why the difference is a security claim, not a performance one.
  • Explain why "physical and logical" isolation is stronger than either alone.
  • Reason about where a tenant identifier must flow for isolation to hold end to end.

Two claims that look alike and are not

"Tenant A cannot see tenant B's data" can mean two very different things.

The weak version: the application, when it queries a shared store, adds a filter — WHERE tenant_id = 'A'. The data all lives together; the boundary is a predicate the code remembers to include. Forget the predicate on one code path, or let an injection slip past it, and the boundary is simply gone. The isolation lives in the application's discipline, and disciplines fail.

The strong version: tenant A's data lives in a partition that tenant B's queries cannot address at all — a separate vector-store partition, a separately scoped document collection, an object-store prefix bound to the tenant's identity. A missing filter no longer leaks data, because there is no shared pool to filter; a query scoped to A physically cannot reach B's partition.

A sovereign platform makes the strong claim. Isolation is a property of where the data sits, enforced at the storage layer, not a property of how carefully the application asks.

Why "physical and logical"

The two words are not redundant.

Logical isolation is the partitioning: distinct namespaces, collections, or partitions per tenant, so a query carries its tenant scope down to the store and the store refuses to return anything outside it. This defeats the missing-filter class of failure.

Physical isolation goes further where the stakes require it: sensitive bulk traffic — the movement of documents and embeddings between compute and storage — travels on a network segment that is not routable from the general application network. Even an attacker who reaches the application tier cannot address the storage path directly. This defeats a different class of failure: the one where the application boundary is breached and the attacker tries to reach the data plane underneath it.

Each alone leaves a gap. Logical isolation without physical isolation trusts the network; physical isolation without logical isolation trusts the application to scope its queries. Together, an attacker must defeat both the partition scheme and the network segmentation, and those are different mechanisms with different failure modes — which is precisely the point of defense in depth.

The tenant identifier as a first-class flow

For storage-layer isolation to hold, one thing must be true everywhere: the tenant identity has to travel with the request, unforgeably, from the edge all the way down to the store — and every store access must be scoped by it.

This is why tenant isolation is not separable from the zero-trust model. The tenant identifier lives inside the same signed context that carries clearance and identity. It is set once, at the edge, and cannot be rewritten by a deeper layer or by the agent. When the retrieval step reaches the vector store, it reaches the partition named by the signed context — not a partition the reasoning loop chose, and certainly not a default that quietly spans tenants.

The failure to watch for is a place where the tenant scope is implicit — a store client configured with a default namespace, a cache keyed without the tenant, a "convenience" path that skips the scoping because it was only ever meant for one tenant during development. Every such place is a potential cross-tenant channel. The discipline that keeps isolation intact is: no store access without an explicit tenant scope drawn from the signed context, ever, on any code path.

A note on the multi-tenant / single-tenant spectrum

Physical-and-logical isolation is what lets one codebase serve very different postures. A commercial deployment may host many tenants on shared infrastructure with strict partitioning between them. A defense deployment may be single-tenant-by-construction — one customer, one enclave, the "multi-tenant" machinery still present but with a tenant count of one. The isolation model does not change between these; only the number of partitions does. This is the same one-platform-many-postures property we met in Why Sovereign AI, now visible at the data layer: the strongest isolation posture is the single-tenant enclave, and the architecture reaches it by configuration, not by removing the multi-tenant code.

Key takeaways

  • Isolation enforced by an application filter is only as strong as the code's discipline; isolation enforced by storage-layer partitioning survives a forgotten filter, because there is no shared pool to leak from.
  • Physical and logical isolation defeat different failure classes — network reachability and query scoping respectively — and together give defense in depth.
  • Isolation holds end to end only if the tenant identifier flows unforgeably from the edge to every store access, with no implicit-default scoping anywhere.

For further study

  1. Enumerate the code paths in a typical RAG system where a tenant scope might be applied implicitly (default namespaces, caches, background jobs, admin tools). For each, describe the cross-tenant leak that a missing explicit scope would create.
  2. Physical network segmentation has a real operational cost and complicates deployment. Construct the argument a security architect would make for requiring it anyway on the bulk-storage path specifically, rather than trusting logical isolation alone there.
  3. In the single-tenant enclave, the multi-tenant machinery runs with a tenant count of one. Is that machinery pure overhead in that case, or does keeping it present buy something? (Consider what changes if the enclave later needs to host a second, differently-cleared workload.)

Next: Clearance-Tiered Inference — routing requests to models by authorization, and why a hardcoded model name hides a skipped question.