Home > General > Configuring Tomcat 6 For https (SSL)

Configuring Tomcat 6 For https (SSL)

May 27, 2011

1. JDK — i used jdk 1.5.x
2. Tomcat 6.xFor any https (SSL) page a certificate is very necessary. First we will learn generating a keystore, which will contain a certificate chain. We will use the keytool command from JDK.

1. Goto the command prompt.

2. Type keytool -genkey -alias tomcat -keyalg RSA (if your path is not set to the java bin directory, please go there and type the command).

3. Now you will prompted for a keystore password give it as changeit (you can give it different but you will have to make some changes later).

4. Enter the details needed.

5. Now alias password will be aksed. It must be same as keystore password.

6. After the end of it a keystore will be generated in “drive”:\Documents and Settings\”username”\.keystore

Now configure “tomcat_home”\conf\server.xml, add the following code:-

You are done with your configuration. Save the server.xml file. Restart your tomcat. Now type https://localhost:8443This should show you the same tomcat homepage but in secured format.

Categories: General
%d bloggers like this: