KMS vs CloudHSM
Choose between the managed key service and a single-tenant HSM cluster, and when to combine them.
KMS is the managed key service that integrates with AWS services. CloudHSM gives you your own HSM cluster in your VPC with keys that only your HSM users control.
Comparison
| KMS | CloudHSM | |
|---|---|---|
| Tenancy | Managed by AWS | Single-tenant cluster in your VPC |
| Key custody | AWS manages the HSMs. You control key policies. | You create HSM users. Only they can use the keys. Independent authentication from AWS. |
| Validation | KMS HSMs are FIPS 140-3 Level 3 validated or in validation | FIPS 140-2 Level 3 or FIPS 140-3 Level 3, depending on instance type |
| Integration | Native with S3, EBS, RDS and most services | Applications call the HSM directly through PKCS#11, JCE or CNG |
| Typical use | Envelope encryption, service encryption, signing | TLS offload, protecting a CA's private key, Oracle TDE |
| Availability | Regional, automatic | Cluster across AZs. You add HSMs. AWS handles patching and backup. |
| Direct encryption size | Up to 4,096 bytes with a KMS key | n/a. Application defined |
| Logging | CloudTrail | HSM audit logs |
Which one to use
| Requirement | Pick |
|---|---|
| Encrypt S3, EBS or RDS with minimal effort | KMS |
| Regulation demands single-tenant HSM and exclusive key control | CloudHSM |
| Need service integration and your own HSM | KMS with a CloudHSM custom key store |
| Offload SSL/TLS for web servers | CloudHSM |
| Generate data keys for envelope encryption | KMS |
Legacy
CloudHSM instance type hsm1.medium is FIPS 140-2. AWS recommends migrating to hsm2m.medium, which is FIPS 140-3 certified. AWS's compliance page notes the hsm1.medium certificate moved to the historical list on 2026-01-04.
Exam signal
"Customer must control the HSM and its users", "single-tenant" or "PKCS#11" means CloudHSM. "Audit every use with CloudTrail and integrate with S3" means KMS.
Exam trap
KMS encrypts only small payloads directly. For large data, generate a data key and encrypt locally (envelope encryption). KMS does not store or manage those data keys.
Related
KMS key types, Certificate Manager