Skip to content

Search EricksonLopez.* Ecosystem

Type a library name, NuGet package ID, .NET type, or architectural concept to search across the portal.

Guides & Recipes — MultiTenancy

Recommended recipes for trusted internal gateways and deterministic unit tests.

Never trust raw X-Tenant-ID headers from public clients without authenticating the caller. When operating behind an internal API gateway, use AddInternalHeaderTenantResolution(expectedSharedSecret, headerName: "X-Tenant-ID", secretHeaderName: "X-Gateway-Secret") so requests lacking the shared gateway secret are rejected.

Use FakeTenantStore, TenantContextBuilder, TestTenantContext, and FakeDbConnection to verify tenant-scoped queries and RLS transaction setup without spinning up external database servers.