HTTPBC 3.0.5 problem analysis

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

HTTPBC 3.0.5 problem analysis

Stefan Müller-Wilken
Dear all,

to make a first step, I've started analyzing the freeze condition we're facing with HTTP BC latest. As for the facts, we can see from a client side that the client's handshake attempt does not receive any reply from the server:

$ openssl s_client -msg -state -connect localhost:9443
CONNECTED(00000003)
SSL_connect:before/connect initialization
>>> SSL 2.0 [length 0077], CLIENT-HELLO
    01 03 01 00 4e 00 00 00 20 00 00 39 00 00 38 00
    00 35 00 00 16 00 00 13 00 00 0a 07 00 c0 00 00
    33 00 00 32 00 00 2f 03 00 80 00 00 05 00 00 04
    01 00 80 00 00 15 00 00 12 00 00 09 06 00 40 00
    00 14 00 00 11 00 00 08 00 00 06 04 00 80 00 00
    03 02 00 80 00 00 ff e6 df 0d 02 ee c3 4c f4 1d
    5e af 55 63 03 95 09 b1 88 b7 9e d5 58 b8 aa 9e
    2b 52 60 72 a2 04 0b
SSL_connect:SSLv2/v3 write client hello A

Switching on all SSL debugging on the server side, I get nothing more than
Using SSLEngineImpl.

This led me to the conclusion, that the server blocks in Grizzly's sun.security.ssl.SSLEngineImpl class and to further track that down, I fired up NetBeans, attached the remote debugger and added a breakpoint on that class.

This again revealed the following output in the remote console, hanging after a few <F8> keystrokes on the last 'User program running':


User program running
Class breakpoint hit for class sun.security.ssl.SSLEngineImpl.
Thread SelectorThread-9443 stopped at SSLContextImpl.java:200.
User program running
Thread SelectorThread-9443 stopped at SSLContext.java:330.
User program running
Thread SelectorThread-9443 stopped at SSLSelectorThread.java:345.
User program running
Thread SelectorThread-9443 stopped at SelectorThread.java:1421.
User program running


The server seems to silently die on SelectorThread.java line 1421. I still have no clue, what happens there, but maybe someone can take over from here?

Cheers
 Stefan
Reply | Threaded
Open this post in threaded view
|

Re: HTTPBC 3.0.5 problem analysis

Stefan Müller-Wilken
... one more thing: to further analyze what's going on, one can download the appropriate Grizzly NIO source package (e.g. grizzly-1.0.19-sources.jar), register that in NetBeans. A good method breakpoint to see the inner workings then would be for class name com.sun.enterprise.web.connector.grizzly.SelectorThread on all method invocations.

Have fun!