Helical Insight application mainly hosted on Apache tomcat application server. There are multiple ways using which we can enable SSL on apache tomcat for ex. HTTPS proxy redirection, AJP redirection, IIS, NGINX, HAProxy, configuring SSL details at apache tomcat level etc. The SSL certificate can be applied at any of the webserver or directly at the tomcat webserver.
In this blog we will talk about details on how to enable ssl and configure details at apache tomcat level.
A. For enabling SSL at apache tomcat, we need to configure the jks file inside server.xml file located at …./tomcat/conf folder.
Sample configurations will look like this :
Above highlighted in blue is jks configuration. To configure SSL in server.xml file we need to create jks (java keystore) file with password. There are multiple methods of creating jks file :
- You can create jks file using command line. Java is prerequisite here. If java is already installed that using keytool, we can create jks file on command line.
- Using some UI tools like “Keystore Explorer”, we can create jks file.
NOTE : In either of above 2 cases, please remember the password of jks carefully. We need to use this password to configure jks file inside server.xml file.
B. Next step is to get SSL certificate file which we can import into this jks which we had created in last step (A). There are 2 options to get SSL certificate.
- Create self signed certificate (Not secure and we don’t recommend this). Please refer this link to learn how to create self signed certificate and use it with Helical Insight.
- There are certificate signing authorities which provides SSL certificate for ex. Godaddy. This will be more secure in nature.
Talking about 2nd option which we recommend, this signing authority will provide a bundle with certificate and private key file. Bundle looks something like below :
This certificate and private key file, we need to import into jks file which we had created before. Command to import will look something like below :
keytool -import -trustcacerts -alias xyz.com –file “C:\Program Files\Helical Insight\hi\xyz.com-1\1a5f5128e4341593.crt” -keystore “C:\Program Files\Helical Insight\hi\apache-tomcat-7\tomcat.jks”
NOTE : Command will vary and this is just for reference.
Below is image of jks file after importing certificate and opening it with tool Keystore Explorer :
After importing certificates into jks, configure it in server.xml along with jks password. Restart apache tomcat and you will able to access your applications deployed in apache tomcat using HTTPS.