I assume that you are trying from within your JSP page to connect to another host using HTTPS (i.e. programmatic https client connections).
I have had similar problems. How I solved my problems was to use the Jakarta Commons HttpClient. It will handle the programmatic https client connection for you. All you have to do is work with the higher level GET and POST requests with optional parameters. For my purposes (getting a textual response from the remote host) it works extremely well. Of course, you do have to have the remote host's TLS/SSL public key in a keystore file pointed to by: System.setProperty("javax.net.ssl.trustStore", strKeyStoreFilename); You will also need to supply the password to the keystore by: System.setProperty("javax.net.ssl.trustStorePassword", strKsyStorePassword); -- Nathan Christiansen Tahitian Noni International http://www.tahitiannoni.com -----Original Message----- From: Lukas Bradley [mailto:[EMAIL PROTECTED] Sent: Sunday, October 12, 2003 11:35 PM To: [EMAIL PROTECTED] Subject: HttpsURLConnection, Tomcat 4.1.27, and jsse.jar I'm having a strange problem with Tomcat and javax.net.ssl.HttpsURLConnection. I'm using Tomcat 4.1.27, JDK 1.4.1_04, and the jsse.jar containing the javax.net.ssl and other fine classes. I've read about certain bugs located here http://java.sun.com/j2se/1.4.2/docs/guide/security/jsse/JSSERefGuide.html#InstallProbs under the heading "Code Using HttpsURLConnection Class Throws ClassCastException in JSSE 1.0.x." That is exactly the problem I am having. However, my command line tests work fine. The JDK works fine by itself. There is no ClassCastException. That means that the regular command-line version of the HttpsURLConnection is wonderful. The JSSE classes are configured correctly using "java". However, if you attempt to hit the jsp located at http://www.dollars.com/URLTest.jsp, you'll get an error message with the aforementioned ClassCastException. Tomcat and/or Catalina are not finding the classes, or are having a rough go with the configuration. Since the JSSE classes now ship with JDK 1.4, I've been having a hard time understanding why we are getting this error. The only two ideas I have are (1) Tomcat is running off an old JDK (which I don't think is the case) or (2) there is some configuration error. Attempting to place the System.setProperty() "kludge-fix" in the JSP, it still doesn't work. Does anyone have any insight as to how the Tomcat/Catalina settings could have the JSSE classes misconfigured? Also read this: http://jce.iaik.tugraz.at/mailarchive/iaik-jce/msg02392.html And this: http://forum.java.sun.com/thread.jsp?forum=2&thread=254821 But, as you will see in the JSP, it doesn't help. I've also tried "javax.net.ssl" in the package property, and it doesn't work. Do any and all searches for "jsse tomcat ClassCastException" and you'll see stuff. I think you might have to explicitly install the JSSE classes into the java \lib\ext directory, which still doesn't make sense, because they should be included in 1.4.1 anyway. Thanks for any and all help. Lukas --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]