Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

unable to use ssl in tomcat

 
Abhi Agar
Greenhorn
Posts: 26
Java MySQL Database Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi there, I am using tomcat 6.0.

I did these things:

1. Did "%JAVA_HOME%\bin\keytool -genkey -alias tomcat -keyalg RSA" on command prompt and used password "changeit".

2. After that, I was able to see a ".keystore" named file at my "C:/users/Abhishek/" folder.

3. Used this setting at "conf/server.xml":--



<Connector protocol="org.apache.coyote.http11.Http11Protocol"
port="8443" minSpareThreads="5" maxSpareThreads="75"
enableLookups="true" disableUploadTimeout="true"
acceptCount="100" maxThreads="200"
scheme="https" secure="true" SSLEnabled="true"
keystoreFile="${user.home}/.keystore" keystorePass="changeit"
clientAuth="false" sslProtocol="TLS"/>

4. Now, i started the server, but unbale to get anything, using this url: "https://localhost:8443/"

Can anybody tell me something? I DESPERATELY need to see this "https" working on my server!!!

Though i think the problem might be this:

I used one more setting in server.xml file, it is provided by default:--

<Listener className="org.apache.catalina.core.AprLifecycleListener" SSLEngine="on" />

I have attached the server.xml file here for you to see.

Thanks in advance.
 
Misha Ver
Ranch Hand
Posts: 470
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Have you checked the log files?
 
Tim Holloway
Saloon Keeper
Pie
Posts: 18012
47
Android Eclipse IDE Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I don't think you can do symbolic substitution (${user.home}/.keystore) in the Tomcat server config file. However, the most common reasons for failure are incorrect pathname for the keystore (which you would get if the symbolic reference wasn't expended) and invalid password on the keystore.

Both of those errors generate explicit messages in the Tomcat logfile. With my typing skills - or lack thereof - I've had the joy of seeing them many times.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic