ExitTenant Isolation: tenant-scoped data access1 / 10
Explanation

One trusted context, two enforcement boundaries

How trusted tenant context constrains data access through row-level policies and tenant-specific encryption permissions, including bypass risks and context leakage during connection reuse. · advanced

A tenant identifier in a URL is a requested context, not authority. Validate the Cognito token's signature, issuer, expiry, and intended audience or client as appropriate to its type. Then authorize the selected tenant against administrator-controlled membership. A valid identity can belong to several tenants; each operation still needs one authorized tenant.

This architecture carries that trusted tenant context into PostgreSQL row policies and tenant-specific key permissions. It uses Cognito user-pool JWTs for application identity, STS for temporary AWS credentials, and KMS for cryptographic operations. IAM defines authorization policies; it does not issue role-session credentials. Secrets Manager retrieves stored secrets; it does not mint tenant-tagged sessions. IAM Identity Center is not the configured Cognito user-pool token issuer.

The diagram shows selected logical exchanges, not every network response. The JWT reaches the application through the client. Database results and KMS responses are omitted; the STS credential return is explicit because the application must use those credentials for decryption.

JWT via clienttenant-scoped transactionauthorized tenant tagtemporary credentialstenant-bound decrypt
Amazon CognitoUser pool: controlled tenant membership
Amazon Elastic Container Service (Amazon ECS)Trusted application: authorization and connection pool
Amazon RDSPostgreSQL: tenant rows, RLS, encrypted fields
AWS Security Token Service (AWS STS)Tenant-tagged role sessions
AWS Key Management Service (AWS KMS)Tenant-specific keys and context conditions

1 / 6 The Cognito user pool issues tokens containing administrator-controlled membership information. Users must not be able to edit attributes that grant tenant membership.

AWS architecture icons are the property of Amazon Web Services. BlowStack is not affiliated with or endorsed by AWS.