HSM (Hardware Security Module): why and when to use one
An HSM (Hardware Security Module) is a tamper-resistant electronic device that generates, stores and uses cryptographic keys without ever exposing them in plaintext outside the enclosure. It is the hardware component that makes qualified electronic signatures (QES) possible under the eIDAS regulation, public-key encryption (PKI), the trust root of a certificate authority (CA), and more broadly any cryptographic operation requiring physical and logical tamper resistance. This guide explains what an HSM is, what it is used for, how it is certified (FIPS 140-2, FIPS 140-3, Common Criteria EAL4+) and how it differs from a TPM or a purely software KMS.
What exactly is an HSM?
An HSM is a hardware appliance (1U rack, PCIe card, USB token or network appliance) that performs cryptographic operations (key generation, signing, encryption, decryption, hashing) inside a sealed physical enclave. Private keys never leave the HSM: any physical extraction attempt triggers immediate erasure (tamper response). The enclosure is designed to resist side-channel attacks (power analysis, electromagnetic emanations, voltage glitching), fault injection attacks, and electron-microscope observation.
Concretely, an application that wants to sign a document sends the SHA-256 hash of the document to the HSM via a standardized API (PKCS#11, KMIP, CNG, JCE). The HSM signs the hash with a private key that lives exclusively in its enclave, then returns the signature. The signed document contains the signature and the matching public certificate — but the private key remains tamper-proof. This is what distinguishes an eIDAS qualified signature (QES, HSM-backed at the trust service provider) from a simple signature (SES, no hardware requirement) or an advanced signature (AES, with a signer-controlled key).
Five use cases where an HSM is indispensable
HSMs are not consumer commodities: they are required as soon as a regulation, standard or contract demands a hardware guarantee of key tamper resistance.
eIDAS qualified signature (QES)
The European eIDAS regulation (EU 910/2014) requires a qualified signature to be generated by a certified qualified signature creation device (QSCD) — in practice, an HSM certified to EN 419 221-5 or Common Criteria EAL4+. The qualified trust service provider (QTSP) operates the HSM that hosts the signer's private key and executes the signature.
Encryption of sensitive data
HSMs manage the master keys (Key Encryption Keys, KEKs) that encrypt database, disk (BitLocker, LUKS) or backup encryption keys. Typical cases: PCI-DSS compliance for payment processors, HIPAA / HDS for health data, defense secret for government agencies.
Certificate authority (PKI)
Every root, intermediate or issuing certificate authority (CA) uses an HSM to generate and use the key that signs X.509 certificates. The root key of a public CA (Let's Encrypt, DigiCert, Sectigo) or a private enterprise CA (Active Directory CS, ADFS) must live inside a certified HSM.
Cryptographic key management (KMS)
Cloud platforms (AWS CloudHSM, Azure Dedicated HSM, Google Cloud HSM) expose shared or dedicated HSMs to manage the full key lifecycle: generation, rotation, derivation, archiving, destruction. The advantage over a purely software KMS: provable tamper resistance defensible to regulators and auditors.
TLS root and critical server certificates
TLS certificates for critical infrastructure (banking gateways, software code signing, IoT manufacturer root CAs) are HSM-protected. The HSM signs outbound certificates without ever exposing the root key — even if the host server is fully compromised.
HSM certifications: what to know
Not all certifications carry equal weight. The certification level determines which regulations the HSM qualifies for (eIDAS QSCD, PCI-DSS HSM, defense contracts).
FIPS 140-2 and FIPS 140-3 (NIST, United States)
FIPS 140-2 (published 2001, retired from the active catalog in 2026) and its successor FIPS 140-3 (in force since 2019, mandatory for new products since 2024) define 4 security levels. Level 3 (keys erased if the enclave is opened) is the minimum for banking and public PKI; Level 4 (resistance to side-channel attacks and environmental variations) is required for certain defense secret uses.
Common Criteria EAL4+ (ISO/IEC 15408, international)
Common Criteria is the international IT security evaluation standard. For HSMs, Common Criteria EAL4+ with the EN 419 221-5 Protection Profile is required by the eIDAS regulation for qualified signature creation devices (QSCDs). That is what European qualified trust service providers (QTSPs) use.
ETSI EN 319 411 and 319 412 (Europe)
ETSI standards define the technical requirements a qualified trust service provider (QTSP) must meet under eIDAS — including the use of HSMs certified to EN 419 221-5. A QTSP listed on the European Trusted List (eIDAS TL) has been audited against these standards by an accredited body (in France: LSTI, COFRAC).
ANSSI (France) and BSI (Germany)
ANSSI publishes a General Security Framework (RGS) and issues "Standard" and "Reinforced" qualifications for cryptographic products. The German BSI publishes equivalent certifications (CSPN, BSI-TR). National public administrations may require these national qualifications on top of European certifications.
HSM vs TPM vs software KMS — which to choose?
The right choice depends on the value of the keys to protect, the regulatory constraints and the budget. Here are the six dimensions that drive the decision.
| Dimension | HSM | TPM | Software KMS |
|---|---|---|---|
| Purpose | Protect enterprise and infrastructure cryptographic keys (QES, PKI, KMS). | Seal boot and identify a machine (BitLocker, TPM 2.0 attestation). One key per machine. | Centralize key lifecycle in memory/on disk, without hardware isolation. |
| Cryptographic throughput | Several thousand RSA-2048 signatures per second (top-tier models: 25,000+ sig/s). | A few signatures per second — built for occasional local use. | CPU-bound (often < 1,000 sig/s for RSA-2048). |
| Regulatory certifications | FIPS 140-2/3, Common Criteria EAL4+, EN 419 221-5 (eIDAS QSCD). | Common Criteria EAL4+ for TPM 2.0 (Microsoft Pluton, Google Titan). Not enough for eIDAS QES. | No hardware certification. ISO 27001 at the vendor at best. |
| Form factor | 1U-2U rack appliance, PCIe card, hardened USB token, or dedicated network appliance. From €8,000. | Chip soldered to the motherboard (TPM 2.0) or virtualized (vTPM). A few euros per machine. | Free (HashiCorp Vault, OpenStack Barbican) or SaaS (AWS KMS without CloudHSM). |
| Typical use case | eIDAS qualified signature, PKI root, PCI-DSS compliance, defense secret. | Secure boot, local disk encryption, Windows Hello attestation. | Application encryption, DevOps secrets, non-critical internal certificates. |
| Total cost of ownership | €8,000 to €80,000 per appliance + maintenance + audit. Shareable via cloud (per-hour pricing). | Marginal cost (already shipped in 99% of post-2016 business PCs). | Free in open-source; ~$0.03/key/month in managed SaaS (AWS KMS, Azure Key Vault). |
Frequently asked questions — HSM
- What is the difference between an HSM and a TPM?
- A TPM (Trusted Platform Module) is a chip soldered to the motherboard of almost every modern business computer — it is used to seal boot, encrypt the disk (BitLocker) and uniquely identify a machine. An HSM (Hardware Security Module) is a standalone appliance dedicated to managing an organization's cryptographic keys — used to sign documents at the eIDAS qualified level, host a certificate authority root, or protect banking encryption keys. A TPM costs a few euros per machine; an HSM costs several thousand to tens of thousands of euros, and only makes sense at the scale of an organization.
- Is HSM encryption truly tamper-proof?
- No protection is absolute, but HSM encryption is today the highest level of hardware protection available. HSMs certified to FIPS 140-3 Level 3 or Common Criteria EAL4+ resist side-channel attacks (power analysis, electromagnetic emanations), fault injection attacks (voltage or temperature glitching), and automatically erase keys if the enclosure is physically opened (tamper response). No public compromise of a correctly operated HSM in production has been documented in the last 10 years.
- Do I need to buy an HSM to use qualified electronic signatures?
- No, unless you are yourself a trust service provider. To sign with QES, your private keys are hosted in the HSM of a qualified QTSP (Universign, Certinomis, LuxTrust and their partners such as Certyneo) listed on the European eIDAS Trusted List. You never see the HSM directly — you interact with it via strong authentication (smart card or Remote QES via MFA + biometrics since eIDAS 2.0).
- What is the difference between an HSM and a KMS?
- A KMS (Key Management Service) is a software service that orchestrates the cryptographic key lifecycle — generation, rotation, archiving, audit. An HSM is the hardware component that physically performs cryptographic operations on those keys. The two are not competitors: a serious KMS relies on an HSM in the background (AWS CloudHSM, Azure Dedicated HSM, Google Cloud HSM). A purely software KMS (no HSM) is enough for non-critical internal uses but does not cover PCI-DSS, eIDAS QES or HIPAA HSM regulatory requirements.
- Who are the main HSM manufacturers in 2026?
- The HSM market is dominated by five manufacturers: Thales (Luna and payShield lines, historical leader), Utimaco (CryptoServer, supplier to many European QTSPs), Atos Eviden (Trustway Proteccio, ANSSI Reinforced qualification), Marvell LiquidSecurity (cloud-native HSM for AWS and Azure) and Entrust nShield. Hyperscalers offer their own pooled options: AWS CloudHSM, Azure Dedicated HSM, Google Cloud HSM. For eIDAS qualified signatures, the decisive criterion is Common Criteria EAL4+ certification with the EN 419 221-5 Protection Profile.
- Can I rent an HSM in the cloud instead of buying one?
- Yes. AWS CloudHSM, Azure Dedicated HSM and Google Cloud HSM rent dedicated HSMs certified to FIPS 140-2 Level 3 (typically between €1 and €3 per hour). For eIDAS qualified signatures, these offers alone are not enough — a qualified QTSP that operates its own HSM and is listed on the European Trusted List is required. The advantage of cloud HSMs is elasticity (no CAPEX, no physical maintenance), at the price of dependence on an often-American hyperscaler (a sensitive topic from a Cloud Act and European digital sovereignty perspective).
- How do I check that a signature provider actually uses a certified HSM?
- The provider must be listed on the European eIDAS Trusted List (https://eidas.ec.europa.eu/) as a QTSP (Qualified Trust Service Provider). This listing is granted only after an audit by an accredited body (in France LSTI/COFRAC, in Germany TÜV) which verifies in particular the conformity of the HSM used to the EN 419 221-5 and EN 419 241-2 standards (Remote QES since eIDAS 2.0). In addition, ask the provider for the Common Criteria certification number of its HSMs — a serious QTSP publishes it in its technical documentation.
To go further
Need an HSM-backed qualified signature?
Certyneo relies on Common Criteria EAL4+ certified HSMs operated by a qualified QTSP listed on the European eIDAS Trusted List. QES from €9.90/act starting on the Standard plan.