With EC key (Self Signed Certificate)

  1. Generate an EC keypair on Utimaco HSM.

›_ Console

# keytool -genkey -alias ibmec -keyalg EC -keystore NONE -storetype PKCS11IMPLKS -providername IBMPKCS11Impl-CryptoServer 

Provide information when prompted Here:

  • EC is the key algorithm

  • NONE is the keystore for HSM

  • PKCS11IMPLKS is the storetype

  • IBMPKCS11Impl-CryptoServer is the provider name

  • ibmec is the key name that will be generated on Utimaco HSM

Provide the keystore password when prompted

tmpjramdr2t.jpg

Keytool command to generate keys

It is recommended to use CA signed certificate for production environment.

  1. Verify the entry with same alias name is generated.

›_ Console

# keytool -list -keystore NONE -storetype PKCS11IMPLKS -providername IBMPKCS11Impl-CryptoServer 

Here:

  • NONE is the keystore for HSM

  • PKCS11IMPLKS is the storetype

  • IBMPKCS11Impl-CryptoServer is the provider’s name

Provide the keystore password when prompted

tmp629fv5cm.jpg

Listkeys output

  1. List the objects using p11tool2.

›_ Console

# p11tool2 Slot=0 LoginUser=ask ListObjects 

Enter user PIN when prompted

tmpedpx5zrc.jpg
tmprywu4ec0.jpg

List keys output using p11tool2

  1. Sign any sample jar file using jarsigner tool.

›_ Console

# jarsigner -tsa http://timestamp.digicert.com -keystore NONE -storetype PKCS11IMPLKS -providername IBMPKCS11Impl-CryptoServer -signedjar sample_output.jar samples.jar ibmec  

Here:

  • http://timestamp.digicert.com is URL of timestamp server

  • Here NONE is the keystore for HSM

  • PKCS11IMPLKS is the storetype

  • IBMPKCS11Impl-CryptoServer is the provider’s name

  • sample_output.jar is the new output signed jar file that will be generated

  • samples.jar is the jar file to be signed

tmp2_6lvw8e.jpg

Signing the jar using jarsigner command

  1. Verify the signed jar.

›_ Console

# jarsigner -verify sample_output.jar -keystore NONE -storetype PKCS11IMPLKS -storepass 12345678 -providername IBMPKCS11Impl-CryptoServer 

Here sample_output.jar is the newly generated signed jar file

tmpv906i_br.jpg

Verifying signed jar


This completes the Integration for IBM PKCS11 with Utimaco SecurityServer.