Folks,

Well, I'm stumped. I've installed keys, etc. in the most straightforward
way, and I'm getting the following mystifying exception:

java.io.IOException: java.security.NoSuchAlgorithmException: Class
com.sun.net.ssl.internal.ssl.SSLContextImpl configured for SSLContext not a
SSLContext

... the strange thing is, the exact same setup (same .keystore, etc.) works
fine under Tomcat 3.2. What's different in 4.0 that's reconfiguring the
SSLContext stuff before we hit ?

I've lifted the code from SSLServerSocketFactory (where the exception is
occurring) and I've called it from a standalone Java program, and I can
create and use it without a problem:

  SSLServerSocketFactory f = new SSLServerSocketFactory ();
  f.createSocket (8081);

... so something must be happening between start of Tomcat and the
HttpConnector.open () that's messing with the SSLContext, right? Where could
this be? I've grepped all over the place, and I'm stumped.

Thanks,
Ben Flaumenhaft.

More information follows:

** I'm using the IBM JDK 1.3 on development Win98 machine.
** I'm using Tomcat 4.0-b1 (the milestone).
** Here are my connectors from server.xml

    <!-- Define a non-SSL HTTP/1.1 Connector on port 8080 -->
    <Connector className="org.apache.catalina.connector.http.HttpConnector"
               port="8080" minProcessors="5" maxProcessors="75"
               acceptCount="10" debug="0"/>

    <!-- Define an SSL HTTP/1.1 Connector on port 8443 -->
    <Connector className="org.apache.catalina.connector.http.HttpConnector"
               port="8443" minProcessors="5" maxProcessors="75"
        acceptCount="10" debug="0" scheme="https" secure="true">
      <Factory className="org.apache.catalina.net.SSLServerSocketFactory"
               clientAuth="false" protocol="TLS"/>
    </Connector>

... which is vanilla from the sample server.xml, uncommented.

** Here's the full text of the trace:

java.io.IOException: java.security.NoSuchAlgorithmException: Class
com.sun.net.ssl.internal.ssl.SSLContextImpl configured for SSLContext not a
SSLContext
        at java.lang.Throwable.<init>(Throwable.java:96)
        at java.lang.Exception.<init>(Exception.java:44)
        at java.io.IOException.<init>(IOException.java:49)
        at
org.apache.catalina.net.SSLServerSocketFactory.initProxy(SSLServerSoc
ketFactory.java:409)
        at
org.apache.catalina.net.SSLServerSocketFactory.initialize(SSLServerSo
cketFactory.java:328)
        at
org.apache.catalina.net.SSLServerSocketFactory.createSocket(SSLServer
SocketFactory.java:281)
        at
org.apache.catalina.connector.http.HttpConnector.open(HttpConnector.j
ava:733)
        at
org.apache.catalina.connector.http.HttpConnector.start(HttpConnector.
java:881)
        at
org.apache.catalina.core.StandardService.start(StandardService.java:3
60)
        at
org.apache.catalina.core.StandardServer.start(StandardServer.java:454
)
        at org.apache.catalina.startup.Catalina.start(Catalina.java:654)
        at org.apache.catalina.startup.Catalina.execute(Catalina.java:595)
        at org.apache.catalina.startup.Catalina.process(Catalina.java:176)
        at java.lang.reflect.Method.invoke(Native Method)
        at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:157)


Reply via email to