Hardware security module (HSM)

A tamper-resistant device that generates, stores and uses cryptographic keys inside its own protected boundary, so that sensitive keys are not exposed in plaintext outside it.

A hardware security module is a dedicated, tamper-resistant device that generates, stores and uses cryptographic keys within its own security boundary. Applications send requests; the HSM signs, decrypts, wraps or generates keys internally, so sensitive keys are designed never to leave it in plaintext. Keys can be marked non-exportable. Where a key must move, for backup or to another module, it is exported wrapped under another key, typically with dual control and split knowledge over the administrative steps. Many HSMs respond to detected tampering by erasing their keys, known as zeroization. HSMs come as network appliances, plug-in cards and cloud services, commonly validated under FIPS 140-3.

Typical uses include protecting the signing keys of a certificate authority, code signing, payment card PIN processing, and master keys for database encryption. The comparison candidates are most likely to meet is with the Trusted Platform Module: a TPM is a chip bound to one platform, used to measure its boot and seal that machine’s secrets, while an HSM is a dedicated key service shared by many systems.

Exam relevance: a scenario asking for the most effective protection for high-value keys is likely to point to an HSM rather than an encrypted key file or access control on a server. Candidates are expected to distinguish an HSM from a TPM by scope and purpose.