Design Partner Program
TENANT ISOLATION

Multi-tenant security testing: prove no tenant can reach another.

Every SaaS customer assumes their data is walled off from everyone else's. That wall is rarely one control. It's a tenant filter repeated in every query, job, cache key, file path and support tool. Multi-tenant testing checks each of those places, as each tenant, on every release.

CANARY DATA · ONE PER TENANTseeded before testing
Acme CNRY-ACME-41f0 admin · member
Globex CNRY-GLOBEX-9d2e admin · member
Initech CNRY-INITECH-c7a3 admin · member
as acme/member GET /api/search?q=invoice → 200 · 42 results · contains CNRY-GLOBEX-9d2e
If a tenant's canary ever appears in another tenant's response, isolation failed. No interpretation needed.
01 · WHERE ISOLATION BREAKS

Eight Places Tenant Isolation Fails in Multi-Tenant SaaS

The main API is usually well guarded. Leaks tend to come from the paths built later, by a different team, or run in the background.

01 Usually tested

Object reads by ID

An endpoint loads a record by ID without checking the caller's tenant.

TEST · Request each tenant's canary object as every other tenant.
02 Often missed

List, search and filters

A search index or filter returns matches across tenants.

TEST · Search for another tenant's canary string.
03 Often missed

Exports and reports

The request is checked; the background job that builds the file isn't.

TEST · Generate exports and scan the file for foreign canaries.
04 Often missed

File storage

Predictable paths or long-lived signed URLs open another tenant's files.

TEST · Reuse paths and links across tenants and after expiry.
05 Often missed

Webhooks and events

Events fan out to the wrong subscriber or include another tenant's payload.

TEST · Subscribe as each tenant and inspect delivered events.
06 Often missed

Caches

A cache key omits the tenant, so one tenant is served another's response.

TEST · Warm the cache as one tenant, read it as another.
07 Often missed

Support and admin tools

Impersonation or internal tools skip the checks customers go through.

TEST · Scope support roles and test what they can reach.
08 New surface

AI assistants and RAG

Retrieval pulls documents from a shared index without a tenant filter.

TEST · Ask each tenant's assistant about another's canary.

"Often missed" reflects where tenant checks are commonly absent, not measured incidence.

02 · ISOLATION MODELS

Pooled, Bridge and Silo: How Each Tenancy Model Leaks

Stronger separation moves the risk; it doesn't remove it. Pick your model to see where testing should focus.

WHAT IT GUARDS WELLCost and operational simplicityOne schema to migrate and monitorRow-level security, if enforced in the database
WHERE IT LEAKSAny query that forgets the tenant filterSearch indexes and caches keyed without tenantReporting and analytics jobs run as a service account
FOCUS TESTING ON→Every list, search and export endpoint→Background jobs and their queries→Cache keys and search index scoping
03 · THE CROSS-TENANT MATRIX

Cross-Tenant Testing: Every Surface, Every Tenant Pair

Three tenants give six directions to test. Each cell asks one question: can the attacker tenant see the victim's canary on this surface?

Isolation sweep · release 4.18 3 tenants · 8 surfaces · 48 checks · read-only
Tested0/48Isolated0Leaked0
SURFACEA→BA→CB→AB→CC→AC→B
Object reads (API)
List & search
Exports & reports
File storage
Webhooks & events
Cache
Support tools
AI assistant (RAG)
Press play to sweep 48 checks. Each runs as a member of the attacker tenant and looks for the victim's canary.
00:00 / 00:20
Isolated: no victim canary returned Leaked: victim canary in response Not yet tested

Illustrative run · synthetic tenants and data · 20 s replay

04 · WHAT A FINDING LOOKS LIKE

Tenant Isolation Example: The Export Job That Forgot Its Tenant

The export endpoint checked the tenant. The background worker that built the file didn't. The leak only appears when you follow the request past the API, into the job and out through the download link.

Illustrative run · synthetic data

Reports export · cross-tenant data in async job API1:2023 · CWE-639 · CWE-284
Critical Validated
SETUP
Tenants acme and globex, each seeded with a canary invoice. Identity: acme/member.
REQUEST
acme/member requests a report export. The API checks the tenant and queues a job.POST /api/reports/export → 202 { "job": "exp_3318" }
JOB
The worker builds the report with a service account. Its query has no tenant filter for one date range.
DOWNLOAD
acme/member downloads the finished file.GET /files/exports/exp_3318.csv → 200 (1,204 rows)
CANARY
Row 877 contains globex's canary. Values beyond the canary are redacted in the evidence record.inv_62210, CNRY-GLOBEX-9d2e, globex, █████
SCOPE
Read-only. The file was deleted after hashing; only the canary match was retained.
Fix and retest: pass tenant context into the job and enforce it in the worker's query; the sweep reruns and the export cell turns green for every pair.
05 · THE TEST PLAN

How to Build a Multi-Tenant Security Test Plan

Six ingredients. Set them up once and the same plan reruns on every release.

Running it safely in production →
01

Three or more test tenants

With different plans, regions or settings, so direction-specific and config-specific bugs show up.

02

Roles inside each tenant

At least an admin and a standard member, plus any support or partner roles that cross tenants.

03

Canary records everywhere

Unique markers in records, files, comments and documents, so leaks are unambiguous.

04

A surface inventory

Every path data leaves through: APIs, search, exports, files, events, caches, tools and AI features.

05

Follow the request

Track work into async jobs, queues and generated files, not just the synchronous response.

06

Rerun on release

Run the full matrix from CI/CD so new features are tested against every tenant pair.

06 · STANDARDS & ASSURANCE

Where Tenant Isolation Evidence Gets Used

Customers' security reviews, your auditors and your own AppSec team all ask the same question in different words.

RISK LIST

OWASP API Security Top 10 (2023)

API1 and API3 (object and property level authorization) and API5 (function level) are the API-layer forms of isolation failure.

USE IT FOR · Classifying isolation findings on APIs.
WEAKNESSES

CWE-639 and CWE-284

Authorization bypass through a user-controlled key, and improper access control more broadly.

USE IT FOR · Recording the root cause developers fix.
ATTESTATION

SOC 2 (logical access)

Logical access criteria cover restricting access to data to authorized users, including between customers in shared systems.

USE IT FOR · Showing auditors isolation is tested, not just designed.
CERTIFICATION

ISO/IEC 27001

Annex A access-control and information access restriction controls apply to multi-tenant data segregation.

USE IT FOR · Evidence that segregation controls operate effectively.
CUSTOMER REVIEW

Security questionnaires

Enterprise buyers routinely ask how tenant data is segregated and how that is verified.

USE IT FOR · Answering with test evidence instead of architecture diagrams.

Summaries are for orientation only. Confirm control mappings with your auditor.

07 · WHERE HAYROK FITS

Continuous Tenant Isolation Validation, With Evidence

Hayrok runs the cross-tenant matrix as each tenant and role you define, follows requests into jobs, files and integrations, and records proof for every cell. Reruns happen on every release, so isolation is a tested property, not an assumption.

01

Tenant and role identities

Define tenants and roles once; every scenario runs as each of them, with tokens managed for you.

02

Canary seeding and matching

Markers are planted in test tenants and matched in every response, file and event.

03

Beyond the synchronous API

Scenarios follow requests into exports, jobs, file links, webhooks and AI retrieval.

04

Matrix on every release

The full tenant-pair matrix reruns from CI/CD; regressions open as validated findings.

05

Evidence per cell

Each pass and each leak is stored with redacted request pairs in Evidence Fabric.

08 · FAQ

Multi-Tenant Security Testing FAQ

Testing whether one customer (tenant) of a shared application can read, change or infer another tenant's data. It covers every path data takes: APIs, search, exports, files, background jobs, caches, integrations and support tools.

BRING THREE TEST TENANTS

See your tenant isolation matrix filled in, cell by cell.

Give us three test tenants with two roles each. We'll seed canaries, run the read-only sweep against staging and walk you through every leak and its evidence.