Creating a self signed certificate
Read this page to learn the procedure to renew or generate self-signed certificates.
About this task
- From the [server_installation]/jre/bin folder launch the following
command where CERTPASS is the password of the certificate and
HNAME is the hostname of the
computer.
keytool -genkeypair -alias default -keyalg RSA -keysize 2048 -sigalg SHA384withRSA -keystore newkey.p12 -storepass "%CERTPASS%" -keypass "%CERTPASS%" -dname "CN=%HNAME%" -validity 365
- Generate the Certificate Signing Request (CSR):
From the [server_installation]/jre/bin folder, run the following command. Replace CERTPASS with your keystore password and FILENAME with your preferred output path (for example, certreq.arm or certreq.csr).
keytool -certreq -alias default -file FILENAME -keystore newkey.p12 -storepass "%CERTPASS%" -keypass "%CERTPASS%"
- Submit the request:
The command generates a file (for example, certreq.arm) in the location you specified. This file contains your public key and identity information and must be sent to your Certificate Authority (CA) to be signed.
- Next
steps:
Once the CA returns the signed certificates (usually the server certificate plus the root/intermediate CA certificates), you will need to import them back into the newkey.p12 keystore.
For more information on how to import the signed certificates and complete the process, see Creating Certificate Authority signed certificates.Note: The key store contains the private key for the certificate and this must be kept secure at all times. It is recommended that the original copy of the keystore is stored in a secure disk, for example an encrypted USB storage device or similar. Keeping a secure backup of the original keystore is also recommended.
Please note that the following instructions only apply to Remote Control Server version 10.1.0.0442 and lower.
Procedure
- Open a command prompt window.
- Go to the Remote Control Server installation directory.
- Change to the [installdir]\java\jre\bin subdirectory on a Windows™ system or the [installdir]/java/jre/bin subdirectory on a Linux™ system.
-
Run
ikeyman.shon a Linux™ system orikeyman.exeon a Windows™ system. - Select .
- Select the database type. (Use PKCS12 for Broker Certificate. Use PKCS12 or JKS for the Server certificate)
- Click Browse, navigate to the location you want to store the keystore, type a filename for your file and click Save.
- Click OK.
- Enter and confirm a password to protect the keystore and click OK.
- Select .
-
Enter a name for the Key Label.
For example, the hostname of the broker.This is the name that will be displayed in the Personal Certificates list in the key management tool GUI.
- Select X509 V3 for the Version.
-
Select a Key Size value.
Recommended value is 2048.
-
Select a Signature Algorithm
This is a cryptographic algorithm for digital signatures and should be left as the default value SHA256WithRSA.
-
Type a Common Name.
Set to the DNS host name and domain of your broker.For example trcbroker.example.com
-
Type the Subject Alternate Name.
Most recent browsers use the Subject Alternate Name to validate the certificate in place of (or in addition to) the Common Name. Make sure you provide a matching subject alternate name. For example server.example.com.Note: Java based certificate tools (like ikeyman) do not support Subject Alternate Names with domain names that start with a number. For example, server.8xxx.com. In this case you need to use OpenSSL or another external tool to create the certificate.
- Enter any additional optional information as required.
-
Enter a Validity Period.
This is the number of days that the certificate will be valid for. Default is 365 days.
-
Click OK.
- Self-signed certificate
- If you plan to use the self-signed certificate, you need to extract the certificate at this point by performing the following steps. You can then copy and paste the content of this file where applicable.
- CA-Signed certificate
- If you plan to use CA Signed certificate, you need to create the CSR at this point
performing the following steps.
- Create a Certificate Signing Request
- Select Recreate Request.
- Indicate the location where to save the certreq.arm file.
- Press OK.
For more information to complete the CA singing process, see Creating Certificate Authority signed certificates.
- Create a Certificate Signing Request