Create the KEK token
Use the command-line program hwsetup to create a KEK token. Read more about hwsetup here: Initialize Hardware Security Module for use in Certificate Manager.
- Run hwsetup to generate a key pair, see Generate DSA/EC/RSA key pair.
- Run hwsetup to create a PKCS #10 request based on the generated key pair, see Generate PKCS #10 certificate request.
- Use Registration Authority (RA) and select the token procedure with storage profile PKCS#10 to import the PKCS#10 request file. Save the issued certificate to file, see Issue certificates from request files.
- Run hwsetup to store the certificate in HSM, see Install certificate.
The KEK token must be configured in the CF service (or in all computers running CF in case of a distributed configuration).
- In kar.conf:
- Add the crypto library to the list of crypto libraries (in the parameter
kar.common.cryptolib.<#>.name
). - Add the new KEK to the list of tokens:
kar.common.token.<#>.tokenlabel
and kar.common.token.<#>.pin
. - Set the new KEK as the key to use for key archiving, that is, change the value for
kar.archive.kek.0.tokenlabel
and kar.archive.kek.0.keylabel
.
- Restart the system in order to make the changes take effect.