Generating a KeyStore and TrustStore
Use the information in this topic to create a KeyStore, create a custom self-signed certificate, and import the certificate.
Related topics
Creating a KeyStore in JKS format
To create a KeySTore in the JKS format, you need to run the following keytool command.
Command syntax
Example
In the preceding command, the following definitions apply:
- <jksFileName> refers to the name of the KeyStore file (.jks format).
- <aliasName>refers to the alias that you want to use while generating the KeyStore.
- <numberOfDays>refers to the number of days for which the KeyStore must remain valid.
- <encryptionType>refers to encryption type that you want to use while generating the KeyStore.
After you create the KeyStore, you need to perform the following additional steps:
- (Optional) Create a custom self-signed certificate. You can also use the default self-signed certificate bundled with the IT Data Analytics product.
For more information, see Creating a custom self-signed certificate. - Import the certificate into the appropriate Java Runtime Environment (JRE) location.
Creating a custom self-signed certificate
To create a custom self-signed certificate, you need to run the following keytool command.
Command syntax
Example
In the preceding command, the following definitions apply:
- <aliasName>refers to the alias used while generating the KeyStore.
- <name> refers to the name with which the certificate file must be created.
- <keystoreFileName> refers to the KeyStore file name (generated in the JKS format).
Importing a certificate
To import a self-signed certificate (default or custom) into a JRE location, you need to run the following command. The JRE location might differ based on the channel for which you are trying to configure security. For more information, see Configuring-a-secured-connection.
Command syntax
Example
In the preceding command, the following definitions apply:
- <jreLocation> refers to location where you need to import the certificate.
The JRE location might differ based on the channel for which you are trying to configure security. For more information, see Configuring-a-secured-connection. - <certificateFileName> refers to name of the certificate file that you want to import. Optionally, you can also include the location path with the file name.
- <aliasName> refers to the alias used while generating the KeyStore.
- <password> refers to the KeyStore password (default: changeit).