Customer-Controlled Encryption Keys in Cloud SaaS Architectures

Customer-managed keys don't guarantee the provider can't decrypt.

· 9 min read
Cover illustration for “Customer-Controlled Encryption Keys in Cloud SaaS Architectures”
Data Sovereignty · November 8, 2026 · 9 min read · 1,922 words

Customer-controlled encryption keys in cloud SaaS architectures are a spectrum of control over where keys live, who can authorize decryption, and what happens when access is revoked. A customer-managed key is not proof that the cloud provider cannot decrypt the data.

Why provider-managed encryption leaves a control gap that matters for regulated SaaS

Provider-managed encryption is the default and covers most low-risk workloads adequately. Its weakness is custody. Cloud Security Alliance’s key responsibility model assigns key generation, storage, rotation, use, and backup to the cloud service provider under this arrangement. Customers configure encryption settings and may see basic reports, but they do not control the key material. The provider holds both the ciphertext and the means to unlock it.

That combination leaves a path to plaintext through legitimate cloud credentials or legal compulsion. The U.S. CLOUD Act allows providers under U.S. jurisdiction to be compelled to provide access with a warrant or customer consent, regardless of where the data is stored. Location alone does not close that gap. For regulated SaaS, control over who can authorize decryption therefore matters. An auditor reviewing a SOC 2 or HIPAA program also needs evidence of who used keys and changed policies, which provider-managed keys expose only to a limited degree.

How the four key management models actually distribute control and responsibility

The four models form a ladder of customer control, but the rungs need clear names. The key object is the managed artifact with policies, versions, and audit logs. Key material is the cryptographic bytes themselves. Even when the customer controls the object, the provider may still be able to reach those bytes. Each step changes both custody and responsibility.

Provider-Managed Keys, or PMK, leave the lifecycle with the provider. Customer-Managed Keys, called CMK or CMEK, give the customer authority over generation, rotation, usage policies, and deletion, while the provider stores and uses the keys within its key management service or hardware security module. These are commonly shortened to KMS and HSM. Bring Your Own Key, or BYOK, is a CMK variant in which the customer generates material externally and securely imports it into the provider’s environment. After import, the provider’s infrastructure performs the cryptographic operations.

Hold Your Own Key, or HYOK, draws the boundary elsewhere. Key material never enters the provider’s environment, and the customer-managed KMS handles key operations and requests. Hybrid arrangements blend these boundaries and include exportable CMKs and Keep Your Own Key models that use single-tenant customer-controlled cloud HSMs. Cloud Security Alliance warns that the labels have no agreed meaning across the industry, so the architecture must explain where material resides and who can authorize its use.

Diagram: The Four Key Management Models: A Ladder of Customer Control. Visualizes: Show four models arranged as a vertical ladder or stepped diagram, ranked from least to most customer control.

What BYOK actually guarantees after import — and what it does not

BYOK establishes key provenance and customer lifecycle control. It does not establish provider technical inaccessibility after import. In a typical deployment, the customer generates material externally, imports it using a provider-supplied import token, and lets the provider’s HSM perform cryptographic operations. The provider can therefore technically decrypt within that environment.

The useful separation in multi-tenant SaaS usually comes from envelope encryption. The application generates a per-object Data Encryption Key, or DEK, and uses it to encrypt the data locally. It then asks the customer’s CMK in the KMS to wrap, meaning encrypt, that DEK. The wrapped DEK sits beside the encrypted data. The master key stays inside the KMS.

At read time, the application retrieves the wrapped DEK, asks the KMS to unwrap it, and decrypts the data locally. The SaaS has permission to request the operation that makes data readable. Revoking the CMK blocks unwrapping without requiring every underlying object to be re-encrypted, subject to any decrypted DEKs still cached. That distinction is central to incident response. The customer can direct revocation immediately, but its practical effect depends on how the application uses and retains DEKs.

SonarQube Cloud Enterprise illustrates this least-privilege boundary. Its CMK/BYOK design grants access to GenerateDataKey, Decrypt, ReEncrypt, and related describe/grant actions in the customer’s AWS account. The service can encrypt and decrypt. Application permissions to read the data it processes remain separate from administration of the customer’s keys, users, or broader KMS configuration.

The compliance value follows those limits. HHS guidance says an incident involving only encrypted ePHI may qualify for HIPAA’s breach notification safe harbor when the provider lacks the decryption key and the encryption meets HIPAA standards. The BYOK label alone does not show that this condition is met. For GDPR erasure, deleting imported material can make encrypted data inaccessible, but AWS allows the same material to be reimported, limiting deletion’s finality. For SOC 2, customer-managed keys expose lifecycle evidence, while a Type II review still requires access logs, change records, and cloud audit logs showing that controls worked throughout the testing period.

Where HYOK draws a harder line — and what it costs to hold it

HYOK addresses a harder requirement than customer-directed lifecycle control. The provider must have no access to the keys. The customer-managed KMS handles key operations, so the provider lacks the material it needs to decrypt on its own. This fits sovereign workloads and contracts that rule out technical access by the provider. It can also put several clouds under one authoritative key system.

That external boundary becomes an availability dependency. AWS External Key Store, or XKS, uses double encryption, and the external key stays in the external key manager. Its real-time calls mean a network partition or HSM outage can cascade immediately into data plane failure. GCP Cloud External Key Manager also uses dual-layer encryption through partners, and a request fails when the external key is unreachable. Neither design makes external custody operationally free.

Dedicated HSM-backed stores also add latency to cryptographic operations compared with provider-managed keys. Network proximity affects that delay. For teams choosing this design, the guidance is to place HSMs in the same region and availability zone as the workloads they serve. Teams must also keep the HSM infrastructure secure, connect key systems to cloud services, and have backup and disaster recovery in place. They must also staff the processes that keep those controls working.

Key loss is the harshest failure mode. If the external master key is deleted or HSM access is lost without recovery, the encrypted data becomes permanently unrecoverable. This is not a reason to dismiss HYOK, but it is a reason not to choose it as a badge of rigor. Its costs are justified where external custody solves a legal, sovereignty, or cross-cloud control requirement. They are harder to justify where customer-directed policies would close the actual gap.

How the choice of key management model differs across AWS, Azure, and GCP

AWS, Azure, and GCP all support customer-controlled key management, but the common label hides differences in mechanics and billing. AWS illustrates the distinction between revocation and permanent erasure. DeleteImportedKeyMaterial removes imported material, yet reimporting the same material reverses that step. Azure key delete also provides a deletion route that can render encrypted data inaccessible. Neither operation’s name alone establishes the full erasure guarantee a compliance program needs.

GCP Cloud KMS bills per active key version, with rates varying across software, HSM, and external protection levels. Key version management therefore has a cost dimension. Its external service supports partners including Fortanix, Futurex, and Thales, while AWS provides the XKS path described above. A model name is not a substitute for the provider’s actual key path.

Multi-cloud adds work because each provider has its own governance, access controls, and key lifecycles. As the team that manages those differences grows, so does the engineering overhead. A central HYOK service can unify authority, but it must be more reliable than any individual cloud’s managed service to avoid becoming the weak link. One key authority also creates one shared dependency.

DEK caching is the main mitigation for per-operation KMS costs at scale. An application keeps a decrypted DEK in secure memory for a short, configurable period, reducing calls to the KMS. Fewer calls reduce cost, but revocation is no longer immediate for that cached key. The cache lifetime defines the exposure window. Cached DEKs must also be cleared on failover, so cache policy is part of both the security design and the settings that govern performance.

Why AI and GPU workloads create a second, distinct key management problem

AI workloads need control over two different kinds of keys. Encryption keys protect data that is stored, while API credentials and tokens control access to model providers at runtime. Fireworks AI reported in October 2026 that internal credentials had been used to read environment variables in customer evaluation jobs, including third-party API keys and tokens stored as secrets. Data-at-rest encryption does not solve that exposure. Runtime credentials need their own lifecycle controls and audit trails.

Confidential computing protects data during execution as well as in storage. NVIDIA’s July 2, 2026 security brief describes confidential computing across multiple GPUs on HGX B200 and HGX B300 through NVLink encryption. The GPU Trusted Execution Environment, or TEE, creates a hardware-enforced boundary against provider access. Access to data and models inside depends on the client’s correct attestation and encryption keys.

Corvex announced a long-term customer GPU lease in January 2026 built around on-premise clusters with hardware-enforced encryption, remote attestation, and payload-free telemetry. The design is for sensitive training and production inference that must meet requirements for sovereignty, compliance, and IP-protection. The architectural change is the important part. The boundary that the customer controls moves from the KMS toward hardware that keeps the infrastructure provider from seeing model weights or inference inputs.

The EU AI Act entered into force in August 2024, with broad applicability from August 2026. Together with GDPR data-sovereignty obligations, it is driving demand for privacy-preserving AI infrastructure. Stored data is only part of the question. Regulated deployments must also account for who can observe data flowing through inference pipelines.

A decision framework for choosing the right key model — and when each one is actually appropriate

The missing control should guide the choice of key model. PMK fits low-risk workloads, constrained budgets, single-cloud environments, and teams without the resources to operate keys themselves. CMK or BYOK fits requirements for customer lifecycle control, audit evidence, and customer-directed revocation. HYOK fits when requirements rule out technical access by the provider or call for one external authority across clouds. Moving up the ladder needs a reason beyond procurement optics.

For a team making that choice, the diagnostic questions should be explicit. Do applicable frameworks, including FIPS 140-3, NIST SP 800-57, ISO/IEC 27001, PCI DSS, or HIPAA, require control of material or only customer-directed policies? Is potential provider access acceptable for the dataset? Can the team secure HSMs and provide recovery without creating a reliability bottleneck? Cloud Security Alliance also identifies hybrid models as increasingly important as post-quantum cryptography requirements mature, making future changes part of the choice.

For multi-tenant SaaS, envelope encryption with customer CMKs is a practical place to start. It allows separation of duties and key rotation without re-encrypting the data underneath, and least-privilege grants keep the application out of key administration. Tenant onboarding must still account for deletion, revocation, caching, and outages. Operational support for secrets management, audit logging, and compliance automation can reduce that burden. Deployment into the customer’s own cloud account also aligns the account’s trust boundary with customer key ownership.

A design should be tested against failure scenarios that make clear what happens when a key is revoked, deleted, unreachable, or still present in a cache. Those answers show whether the team has bought lifecycle control, external custody, or a promise the architecture cannot keep.

Sources

  1. Choosing a Cloud Key Management Model
  2. Multi-Cloud KMS Recommendations
  3. What Is Bring Your Own Key (BYOK)?
Filed underData Sovereignty

More in Data Sovereignty