Tomcat and SSL

Hi I'm getting an error when I try to run SSL with tomcat. Does anybody know how to solve this. THanks for your help in advance

Starting tomcat. Check logs/tomcat.log for error messages

2001-08-20 03:47:44 - ContextManager: Adding context Ctx( )

2001-08-20 03:47:44 - ContextManager: Adding context Ctx( /test )

2001-08-20 03:47:44 - PoolTcpConnector: Starting HttpConnectionHandler on 8080

FATAL:java.net.BindException: Address in use: JVM_Bind

java.net.BindException: Address in use: JVM_Bind

at java.net.PlainSocketImpl.socketBind(Native Method)

at java.net.PlainSocketImpl.bind(PlainSocketImpl.java:397)

at java.net.ServerSocket.<init>(ServerSocket.java:170)

at java.net.ServerSocket.<init>(ServerSocket.java:121)

at javax.net.ssl.SSLServerSocket.<init>([DashoPro-V1.2-120198])

at com.sun.net.ssl.internal.ssl.SSLServerSocketImpl.<init>([DashoPro-V1.

2-120198])

at com.sun.net.ssl.internal.ssl.SSLServerSocketFactoryImpl.createServerS

ocket([DashoPro-V1.2-120198])

at org.apache.tomcat.net.SSLSocketFactory.createSocket(SSLSocketFactory.

java:120)

at org.apache.tomcat.service.PoolTcpEndpoint.startEndpoint(PoolTcpEndpoi

nt.java:239)

at org.apache.tomcat.service.PoolTcpConnector.start(PoolTcpConnector.jav

a:188)

at org.apache.tomcat.core.ContextManager.start(ContextManager.java:527)

at org.apache.tomcat.startup.Tomcat.execute(Tomcat.java:202)

at org.apache.tomcat.startup.Tomcat.main(Tomcat.java:235)

[1592 byte] By [micksta] at [2007-9-26 4:30:31]
# 1

One of two issues, I believe:

1.) You are trying to bind your SSL capabilities to port 8080 which is already in use by the tomcat server so the SSL part of your server throws an error when it tries to bind to it.

2.) Your SSL capabilities are trying to bind to port 443 but another server/application has already reserved this port for something else.

run a 'netstat' and look for what ports are being listened to.

Hope this helps,

RG

rgorrie1 at 2007-6-29 17:43:05 > top of Java-index,Security,Java Secure Socket Extension (JSSE)...
# 2

> trying to bind to port 443

This is the default HTTPS port, used when you are only specifying the protocol (HTTPS:) without an explicit port, like https://localhost/something. Just like the default port for HTTP: would be 80. A default setup of Tomcat simply adds 8000 to the default ports, making them 8080 and 8443.

Hmmmm, I do not see any reference to the 443 port in the posted error -- the only problem I see is the 8080 port.

"Micksta" wrote:

> I try to run SSL with tomcat

Does this imply you have changed Tomcat's server.xml to handle SSL, or that you forward SSL request from a webserver to Tomcat?

Just to be sure: a single Tomcat instance handles both HTTP: and HTTPS: (if setup to do that). In other words: you do not have to run Tomcat twice to support both HTTP: and HTTPS:. When you want to use the default ports (80 and 443) and also have another webserver running (like Apache) then you would need to forward the requests from Apache to Tomcat.

a.

avbentem at 2007-6-29 17:43:05 > top of Java-index,Security,Java Secure Socket Extension (JSSE)...