Using AWS KMS with the Hyperswitch card vault and what it changes
A platform team running self-hosted Hyperswitch on AWS usually needs the card vault and encryption service keys held under AWS Key Management Service (KMS) rather than in files or Kubernetes secrets inside the cluster. The aws backend option in the vault and encryption service charts is the documented way to point those services at KMS instead of local key material. Teams usually choose it when their cloud security standard already requires customer-managed keys, central key policy and CloudTrail records of key use, and when they want key administration to sit with the same team that runs their other AWS encryption. The Hyperswitch self-hosting documentation includes an AWS deployment path, so this is the natural starting point for an AWS-hosted stack. Before you commit, confirm with the Hyperswitch release you plan to run which values keys the chart accepts for the AWS backend, and whether the vault and encryption service each read the same or separate KMS keys.
The decision has consequences beyond one chart value. Moving key storage to KMS changes who can unlock and use the keys, how the services authenticate to AWS, and what an incident responder can inspect. On EKS, the services should get AWS access through IAM roles for service accounts rather than static access keys stored in a secret, so the pods assume a narrowly scoped role that can only call the KMS operations the services need on the specific key. Plan the key policy, the IAM role trust relationship and the region together, because a key created in one region cannot be used from a service running in another. Ask your Hyperswitch or DeployOpen contact to confirm which settings move out of local configuration and which still need to be set by hand, and record that list in your change plan.
A KMS backend does not remove the dual control and custodian work that the vault still requires. The master and custodian keys, the unlock sequence after a restart and the runbook for a departing custodian are covered in the custodian section of this guide, and KMS access does not replace them. Test the design before real card data arrives. Confirm that a pod restart recovers cleanly, that an IAM role revocation fails closed, that a disabled or deleted key is detected by monitoring, and that KMS and CloudTrail logs show the calls you expect. Treat the cloud account that owns the key as part of your PCI DSS scope and document who can change its key policy.
Key storage options for the Hyperswitch vault and encryption service
This table compares the four key storage choices a self-hosting team weighs for the vault and encryption service: AWS KMS, HashiCorp Vault, an HSM and a cloud KMS from another provider. Read each row against your hosting footprint and who will operate the backend, then confirm the backend options and their settings in the Hyperswitch documentation before you commit.
| Option | Where it fits | Who operates it | Confirm before choosing |
|---|---|---|---|
| AWS KMS | Stacks running in AWS, especially EKS clusters where pods can assume an IAM role for service accounts | Your cloud team, through AWS account, IAM and key policy administration | Which key types and key settings the aws backend in the charts expects, and the region and key ARN format |
| HashiCorp Vault | On-premise or multi-cloud stacks that already run Vault for secrets, or where you want one backend across environments | Your platform or security team, including Vault high availability, unsealing and token lifecycle | The token and URL settings the vault backend requires, and how the chart handles token renewal |
| HSM (hardware security module) | Regulated environments that require keys to stay in dedicated hardware with tamper resistance and custodian-controlled access | Your security team with the HSM vendor, plus a separate custody procedure for the device and its credentials | Whether the documented HSM option for the encryption service matches your device, and what key import and backup steps it needs |
| Cloud KMS on another provider | Stacks hosted outside AWS where the provider's key service is already approved and audited in your environment | Your team for that provider's account and policies, with network access from the cluster to the key service | Whether Hyperswitch documents a backend for that provider, since the AWS and HashiCorp options may be the only ones shipped in the charts |
| Operational ownership | Every option moves key custody into a system you run, so the chosen backend becomes part of your change and access reviews | Named owners for the backend, its credentials and its audit logs | Who approves key rotation and how unlock or access recovery works after an outage |
| Audit and evidence | Assessors will ask who can use the key, how use is logged and how access is revoked | Your compliance team with the platform team, using key policy and logging output from the chosen backend | Which audit logs the backend emits and where Hyperswitch records key operations, if anywhere |
What moves out of local configuration when KMS takes over
When the aws backend is selected instead of local key configuration, the most visible change is that the master key stops being a value your deployment holds and becomes a reference to a customer managed KMS key. The settings that carry that reference move into the chart values for the vault and encryption service: the KMS key identifier (a key ID, ARN or alias, depending on what the chart accepts), the AWS region where that key lives, and the pod identity that calls KMS. Exact value names differ between chart releases, so confirm the keys in the chart README for the release you run before writing any values file. Remove the local key material from the values and secret stores once the KMS path is verified, so that a leaked values file cannot be used to recover the locker keys.
The pod identity change is the one most likely to be misconfigured. On EKS, the service account used by the vault and encryption service should be bound to an IAM role through IAM roles for service accounts, and that role should allow only the KMS operations the service needs against the one key. Confirm the operation set in the chart documentation rather than granting broad kms:* permissions. Who can administer the key moves into AWS as well: the key policy, the IAM policies attached to administrators and any grants become part of the key custody record, alongside your custodian roster. Review them together, record who can change the policy or schedule deletion, and keep an audit trail of changes using AWS CloudTrail. Any drift between the key policy and the custodian procedure is a finding an assessor will ask about.
How to set up the AWS KMS backend on EKS
This sequence takes a platform team from an undecided key setup to a Hyperswitch card vault and encryption service that run on EKS and use AWS KMS for key operations. Each step closes with a check so the team knows whether to move on. The first run happens in a non-production cluster, so key access problems surface before any real card data is involved.
Create or choose the KMS key in the target region
The platform team, working with the security team, selects the AWS account and region where the vault and encryption service will run, then creates a symmetric customer managed KMS key in that region for the vault and encryption service. Record the key ID and ARN, and confirm the region matches the EKS cluster and the data residency commitments you have made to merchants. Keep the non-production key separate from the production key. Check: the key exists, is enabled, and its ARN is written into your deployment records for both environments.
Define the key policy and administrators
The security team writes the KMS key policy so that a small set of named administrators can manage the key, while only the IAM role used by the vault and encryption service can call decrypt and encrypt operations on it. Keep administrative actions such as key deletion and policy changes separate from runtime use. Review the policy with the custodians who will own the key lifecycle. Check: a policy review confirms that no broad principal, such as the whole account, can use the key, and that the administrators are named individuals or approved roles.
Create the IAM role and trust policy for the service account
On the EKS cluster, the platform engineer confirms that the cluster has an OIDC identity provider registered with IAM, then creates an IAM role whose trust policy allows the Kubernetes service account used by the vault and encryption service to assume it. The role policy grants only the KMS actions the service needs on the key from the previous step. Create the service account in the target namespace with the role annotation. Check: the service account shows the role annotation, and an AWS identity check run from a test pod returns the expected role session.
Set the aws backend and region in the charts
The platform engineer sets the key backend to aws in the values for the vault and encryption service charts, along with the KMS key identifier and region, and points the chart at the service account created in the previous step. Values that are currently local configuration, such as the local key material, move out of the chart values and into KMS-managed references. Confirm the exact key names against the chart version you deploy, because they change between releases. Check: rendering the charts with the new values produces manifests that reference the aws backend, the correct region, and the intended service account, with no local key material left in the output.
Deploy to a non-production cluster
The platform team deploys the vault and encryption service to a non-production EKS cluster using the same chart and values structure planned for production, through the deployment pipeline your team already uses. Watch the rollout and the pod logs during startup, since configuration errors often appear only when the service first calls KMS. Keep the production values in a separate file so that nothing non-production is promoted by accident. Check: pods reach a ready state, and the logs show the service initialized the aws backend without falling back to local key material.
Verify startup and decrypt a test value
The platform engineer runs a test that encrypts a known sample value through the encryption service, then decrypts it, and confirms the round trip returns the original value. The test uses a dummy value only, never real card data or real merchant credentials. Note any error the service returns, because permission errors from KMS usually name the missing action. Check: the decrypt result matches the sample, and the services report healthy after the test.
Confirm access is logged in CloudTrail
The security or platform team checks AWS CloudTrail for the KMS Encrypt and Decrypt events created by the test, and confirms they are attributed to the service account role rather than a shared user. Confirm that your organization's log retention and access review processes cover these events. Ask your auditors which evidence they will expect for key use before production. Check: the test events appear in the expected trail with the correct role identity, and the team has recorded where the evidence lives.
How the vault, encryption service and KMS connect on EKS
The diagram starts at the Hyperswitch app server, which calls the card vault and the encryption service inside the cluster. Each of those pods runs under its own Kubernetes service account, and that account is linked to an IAM role through the cluster's OIDC provider, so the pod receives temporary AWS credentials without a static key in its configuration. The role's policy permits cryptographic calls against one KMS key in the chosen region. Check that each service account annotation matches the role, that the key policy names the role, and that every call to KMS stays inside the client's AWS account boundary.
Service account to IAM role to KMS path inside the client's AWS account.
Security controls to design before the first saved card
The KMS backend turns the vault's key material into a cloud-managed control, so the controls around it decide who can unwrap card data. Design them before the first saved card, because your PCI DSS scope follows the vault, and the vault follows the key.
Scope the IAM role trust
Bind the IAM role to the exact Kubernetes service account and namespace that run the card vault and encryption service, using the trust policy conditions for the service account subject. A wildcard subject or a shared role across workloads lets another pod request decryption. Check the trust policy with a test pod in a neighboring namespace, which should fail to assume the role. Confirm the exact condition keys against current AWS documentation for IAM roles for service accounts on EKS.
Hyperswitch self-hosting docsSeparate key administrators from callers
The KMS key policy should split administrative actions (editing the policy, scheduling deletion, changing rotation) from cryptographic actions (encrypt and decrypt). The vault's role should have only the decrypt and data key operations it needs. Administrators should not also hold decrypt rights, or one person can both change the policy and read card data. Ask your team to write this split down before the first deployment.
Log every KMS call
Enable AWS CloudTrail for the account and region that host the key, so every encrypt, decrypt and policy change is recorded with the calling role. Route those logs to a store that the application team cannot edit. Alert on decrypt calls from unexpected principals and on any key policy change. Confirm your retention requirement with your compliance team, since logs of cardholder data access are often part of PCI DSS evidence.
Confirm key rotation settings
Decide whether automatic rotation is enabled for the customer managed key and how the vault handles data encrypted under earlier key material. Rotating the KMS key does not re-encrypt stored card data by itself, so plan the re-encryption path before you turn rotation on. Check the current AWS documentation for how rotation applies to symmetric keys and how the rotation period is set, rather than relying on a default you have not read.
Plan cross-account and multi-region use
A key in one AWS account or Region is only usable from another if the key policy and the calling role both allow it, and a multi-Region key is a separate design choice. If the vault runs in a different account from the key, or in a second Region for failover, the data path and the audit trail both change. Document which account owns the key, which accounts call it, and whether a Region outage would stop card decryption. Validate the Region behavior in a test before go-live.
Recover access after a misconfiguration
A bad key policy or trust condition can lock out the vault on its next restart, and the vault cannot store or read cards until access returns. Keep a break-glass path owned by a named administrator, documented in your runbook, and test it in a non-production account. Restore the previous policy from version control, not from memory. Treat the PCI DSS scope of any emergency access as in scope, because the merchant remains fully responsible for PCI DSS certification and data handling under the in-house model.
In-house PCI model docsHow the AWS KMS path differs by cluster and cloud setup
This is the setup the AWS backend is most directly designed around: the cluster, the KMS key and the vault and encryption service pods all sit in one AWS account and region. The workload identity model on EKS is the piece to confirm with your platform team and against the Hyperswitch Helm chart values, since the exact mechanism must match what the chart expects. Calls to KMS stay on AWS networking, so reachability is usually a question of endpoints, routing and policy rather than internet egress.
- Identity: Confirm which service account identity the vault and encryption service pods use, and that the IAM permissions are scoped to the single KMS key they need.
- Network: Confirm that the nodes or pods can reach the regional KMS endpoint, including any private endpoint and egress controls you apply.
- Latency and dependency: KMS calls are on the unlock and decrypt path, so a regional KMS issue can block vault operations even when the cluster is healthy.
- Disaster recovery: Plan for a second region only if the KMS key and its replication or recovery approach are designed for it, and confirm how the key is restored.
- Ownership: Record who owns the key policy, so that key administration stays separate from the people who deploy the charts.
Before go-live, check the identity mechanism, the key policy and a failed-call test in a non-production account.
Self-managed Kubernetes running on EC2 instances in an AWS account can still use the AWS backend, but the identity step is different from EKS and must be designed rather than assumed. Nodes, control plane and workloads often share a single instance profile unless you separate them, which makes the blast radius of a compromised pod larger. The cluster also needs its own network path to KMS, and that path is often more manual than on EKS.
- Identity: Confirm with your platform team how workload credentials are issued to pods, and whether the instance profile is shared with other workloads.
- Network: Confirm VPC routing, DNS resolution and any proxy or NAT path that the nodes use to reach the regional KMS endpoint.
- Scope of access: Limit which pods can request KMS operations, since a shared node role can grant access to every workload on that node.
- Operations: Track the cluster's own upgrade and certificate work, because a broken control plane also stops the vault from restarting cleanly.
- Disaster recovery: Record the recovery order for the cluster, the KMS key access and the vault unlock steps, since each depends on the previous one.
Before go-live, test a pod restart on a different node to confirm the identity still resolves and the vault can unlock.
A cluster in your data center that calls AWS KMS over the network is the most dependency-heavy setup. Every unlock and decrypt crosses your WAN or internet connection, so the vault inherits the latency, packet loss and outage profile of that link. Identity also has to be established from outside AWS, which usually means a federated or externally issued credential rather than anything tied to the cluster itself. Confirm the exact mechanism against current AWS guidance and the chart documentation before you rely on it.
- Identity: Confirm how the on-premises workload obtains AWS credentials, how they are rotated, and who can revoke them.
- Network: Confirm the route to the regional KMS endpoint, the firewall rules that allow it, and whether traffic crosses a path you do not control.
- Latency and dependency: Measure KMS call latency from the data center, since slow unlocks after a restart extend outage time for card operations.
- Compliance review: Confirm with your assessor where key material and cardholder data sit, because the KMS call path affects your data-flow documentation.
- Disaster recovery: If the WAN link fails, the vault may not unlock. Plan an alternative key backend or a documented fallback and test it.
Before go-live, run a failure test that cuts the link to KMS and confirm the vault fails closed and recovers in the order you documented.
Limits to confirm in your environment before go-live
The AWS KMS backend depends on four moving parts: the chart, the Hyperswitch release, any required dependency, and your AWS account. Each item below is a check to run against your own environment, not a promise that the stack will behave a certain way.
Chart support for the aws backend
Confirm that the release of the vault and encryption service charts you plan to deploy supports the aws backend, and read its values file for the exact key that selects it. Chart releases change, so check the chart version you pin rather than the latest documentation. If the chart does not expose the backend, the KMS path is not available in that version, and you need to decide whether to pin an older chart or change the key storage design before build starts.
Release compatibility with the chart
Hyperswitch ships roughly monthly minor releases, and each one publishes its own compatibility matrix for Control Center and web client versions. Match the router, vault and encryption service versions to the chart version you pick, and recheck the matrix at every upgrade. Treat the matrix as the source of truth for your pinned set, since a release that works with one chart may not work with another.
Hyperswitch releasesRequired dependencies in the deployment
Check whether the release you target needs services beyond the router, vault and encryption service. Superposition became a required configuration dependency in v1.124.0, and deployments must have a Superposition service running before upgrading to that version. Confirm the same for any release you adopt, because a missing dependency can block startup regardless of how the KMS backend is configured.
Release notesKMS quotas and request rates
Ask your AWS account team and review the Service Quotas console for KMS in the target account and region, including request rate limits for cryptographic operations. Vault unlock, encryption and decryption calls all reach KMS, so a busy stack or a restart storm can hit throttling. Load test the expected peak against those limits and record the headroom before you set replica counts.
Regional availability of KMS features
Confirm that the KMS features your design uses, such as the key types and key policies you need, are offered in the Region where the cluster runs and in any Region you plan to use for recovery. Do not assume a feature is available in every Region because the service exists there. Check the current AWS documentation for each Region on your shortlist.
Exact fields each chart version expects
Read the values schema of your pinned chart version and list every field the aws backend requires, including the KMS key identifier, the Region, and the service account name for IAM roles for service accounts on EKS. Field names and structure can differ between chart versions, so a values file copied from another release may load but fail at runtime. Validate the rendered manifests in a non-production cluster before go-live.
Questions teams ask before configuring AWS KMS for Hyperswitch
How much does it cost to configure AWS KMS for the Hyperswitch vault?
No price is published for this work, and any figure you see should come from a written quote based on your scope. The cost is mostly labor: the platform engineer hours to configure the chart values, the IAM role and KMS key policy, and the verification run, plus the time of the AWS account owner and whoever approves key policy. Cloud KMS charges for keys and API requests are a separate, recurring line on your AWS bill, so ask for them to be estimated against your expected vault and encryption traffic. Costs rise with the number of AWS accounts and regions, the number of encryption keys you plan to manage, and how many environments need the same setup.
How long does AWS KMS setup take for the Hyperswitch card vault?
The duration depends on how far the AWS account and EKS cluster are from being ready. If the KMS key, IAM role for service accounts and namespace already exist, the change is mostly chart configuration and a controlled restart. If the team has to design the key policy, agree on who administers KMS, and build the test path in a non-production environment first, the work takes longer. Confirm the timeline with your own change calendar, since the vault and encryption service are sensitive and usually go through a change review before production.
What must our team provide before the KMS configuration starts?
Plan to provide four things: an AWS account and region where the KMS key will live, an EKS cluster with the Hyperswitch namespace and access for the platform team, an AWS IAM administrator who can create roles and policies, and a KMS administrator who will own the key policy. You also need access to the Hyperswitch Helm charts for the vault and encryption service at the version you intend to run. Name the people for each role in writing. Without a named KMS administrator, key policy changes tend to stall or get made informally.
Can one platform engineer configure the AWS KMS backend alone?
A single experienced platform engineer can often do the chart and IAM work, but a second person should review the key policy and the IAM trust relationship before production. The risk is less in the typing than in the separation of duties: the person who edits the key policy should not be the only person who can approve it, and the vault is a card data system where dual control is expected. Ask your compliance lead which approvals they need on record, and plan for the engineer to be available during the first restart.
What recurring work follows after AWS KMS is configured?
Recurring work includes reviewing the KMS key policy and IAM role on a schedule, auditing which principals can call KMS, and checking CloudTrail records for key use. You also need to plan chart and release upgrades, because the Hyperswitch release cadence and compatibility requirements change which chart values you set, and every upgrade should be tested against the KMS path before production. Budget for key rotation decisions and for testing restores of the vault data alongside KMS access, since a working KMS key is useless without the matching encrypted data.
What breaks most often when the Hyperswitch vault uses AWS KMS?
The most common failures are an IAM role that the service account cannot assume, a key policy that does not grant the vault role the decrypt action, and a region mismatch between the configured KMS key and the cluster. Confirm the exact values for the aws backend against the chart documentation for your version, including the key identifier, region and service account annotation. Test a fresh pod start after each change, because a configuration that works for a running pod can fail on the next restart.
When is outside help worth buying for AWS KMS with Hyperswitch?
Outside help is most useful when the team has no one who has configured KMS key policies for regulated workloads, when the vault must pass an assessment soon, or when several environments and accounts need the same pattern. DeployOpen plans, implements, hardens, documents and supports self-hosted open-source platforms in your own cloud accounts, under a fixed scope agreed in writing before work starts. Ask any partner to name the deliverables, the test evidence, and who keeps the KMS policy after handover.
How DeployOpen works on this
DeployOpen plans, builds and hands over the AWS KMS backend for the Hyperswitch card vault and encryption service inside your own AWS accounts and EKS clusters. Each step is agreed in writing first, so your security, platform and compliance teams know exactly what is configured, who can use the key and what evidence they receive.
How we scope
- Confirm the AWS account structure, regions and EKS cluster that will host the vault and encryption service.
- Agree the KMS key policy, key administrators and the roles allowed to call encrypt and decrypt.
- Define which settings move from local chart values to the aws backend and who owns each one.
How we build
- Create the KMS key and IAM roles for service accounts, then wire the key region and role into the chart values.
- Test vault startup, unlock and a saved-card round trip in a non-production cluster before production.
- Review the configuration against your access and audit logging requirements and record the changes made.
How we hand over
- Deliver the configuration, IAM policy documents and a runbook covering key rotation and role changes.
- Walk your platform and security engineers through the restart, failover and key access procedures.
- Document the evidence your compliance team needs, while independent auditors make any assessment decisions.
How we support
- Engagements are fixed-scope, with scope, deliverables and timelines agreed in writing before work starts.
- Ongoing support, upgrades and continuous testing are available as a retainer after handover.
- Ask for a written quote based on your scope, since DeployOpen does not publish a price list.

