OpenSSL version 1.0.2.h for Windows 64-bit machines is used for this demo. OpenSSL
is also available on many Linux distributions and can be installed with your distribution's
package manager.
The Java JDK can be downloaded from Oracle:
http://www.oracle.com/technetwork/java/javase/downloads/index.html
Java JDK version 1.8.0_101 is used in this example.
3.1 Create .pfx file
Use OpenSSL to create .pfx file from certificate and private key. This file is required by
the Java keytool to create a Java keystore file. You may need to add the OpenSSL \bin
folder to your PATH variable if the installation didn't add it automatically. To do this, right
click on "Computer" in Windows Explorer and click on "Properties" and then "Advanced
system settings". Click on "Environment Variables" and find the system variable named
PATH. Select "Edit" and append your OpenSSL \bin path to the "Variable value" field.
Next, perform the following steps to create the file:
● Open the Command Prompt as an administrator
● Navigate to the folder containing your certificate and keys
● Set the location of the RANDFILE that is required by OpenSSL:
set RANDFILE=.rnd
● Create the .pfx file:
openssl pkcs12 -export -out my_pfx_out.pfx -inkey
2a6d9b3215-private.pem.key -in
2a6d9b3215-certificate.pem.crt -name "my_keystore"
-certfile
"VeriSign-Class%203-Public-Primary-Certification-Author
ity-G5.pem"
Note : the file names in bold will have to be changed to the names of your private
key and certificate files
Important : remember the password you entered when creating the .pfx file. We
will use it later when uploading the files to the modem. The password used in
this example is "123456".
The "-name" parameter will also be used later as the alias associated with the
keystore we created. Its value in this example is "my_keystore".