Hardware key generation and secure key storage
Hardware key generation means the private key is created inside a security boundary and never leaves it in the clear. The boundary protects the key from extraction; it does not make the key unpredictable. That property comes from the entropy source inside the boundary, and it is the one most often assumed.
What happens inside the boundary
A key generation request arrives. The module draws from its entropy source, conditions the output, seeds or reseeds its DRBG, and derives key material — for RSA, searching for primes; for elliptic curve, a scalar in range; for ML-KEM or ML-DSA, sampling as the algorithm specifies.
The private key is stored inside and never exported in the clear. Only the public part leaves, plus whatever operations the module performs on request.
Two separate properties
Confidentiality is what the boundary provides: the key cannot be read by the host, by an operator, or by an attacker who compromises the software.
Unpredictability is what the entropy source provides, and the boundary contributes nothing to it. A key drawn from a weak source inside a certified module is a weak key that is extremely well protected — and the protection makes it harder to notice, not easier.
Where the entropy actually enters
At exactly one point: the module's entropy source seeding its DRBG. Everything after that is deterministic derivation. If the seed carried less entropy than assumed, every key derived from it inherits the deficit, and no property of the module detects that.
Which is why the questions in verifying a source you did not build apply as much to a module vendor as to a component vendor. "The key was generated in hardware" is a statement about confidentiality only.
The algorithms differ in how they consume it
- RSA — a search for primes, consuming a variable and often substantial amount of entropy.
- Elliptic curve — a single scalar in range. Cheap, and unforgiving: bias in the scalar is directly exploitable.
- ML-KEM and ML-DSA — sampling from specified distributions, with the same underlying requirement. The dependency does not change with the algorithm generation.
What to require
That the module can state its entropy source, its min-entropy estimate and what it is conditional on, what health testing runs in service, and what it does when the source fails. Refusing to generate is the correct behaviour and should be demonstrable.
Keep reading
- The components
HSM, TPM and secure element compared
An HSM is a high-performance appliance for key operations at scale. A TPM is a low-cost fixed-function chip for platform integrity and attestation. A secure element is an embedded tamper-resistant chip holding a device's identity. They differ in throughput, cost, physical protection and what they are meant to protect.
- The components
The TRNG inside your SoC, what your silicon vendor does not tell you
Most systems already contain a TRNG — inside the SoC, provided by the silicon vendor, usually based on ring-oscillator jitter. It is rarely documented in enough detail to evaluate: the entropy model, the min-entropy estimate and what health testing runs are often not in any datasheet you can obtain.