[ grinder-Bugs-3505060 ] TCPProxy fails to handle concurrent HTTPS requests

SourceForge.net <[email protected]> Mon, 19 Mar 2012 04:40:54 -0700
Newsgroups gmane.comp.java.grinder.devel
Message-ID <[email protected]>
Bugs item #3505060, was opened at 2012-03-15 02:12
Message generated for change (Comment added) made by bushwakko
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=118598&aid=3505060&group_id=18598

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: TCPProxy
Group: None
>Status: Open
Resolution: Fixed
Priority: 6
Private: No
Submitted By: Anders Storsveen (bushwakko)
Assigned to: Philip Aston (philipa)
Summary: TCPProxy fails to handle concurrent HTTPS requests

Initial Comment:
I've been trying to record via https for a while now, but I've been having some troubles. I've managed to add the grinder certificate to java's keystore and I've managed to get my browser to accept the certificates that are involved in my transactions (Firefox silently fails with all certificates that are needed on indirect transactions like a picture linked on a page etc). I'm having huge troubles with other browsers than firefox 9 though (firefox 11 fails, and chrome and safari doesn't work either).

With firefox 9, it seems to work, but it randomly fails to load a certain number of the elements on the page. For instance, it seems to have trouble loading about half of the elements. They seem to either go through at 31seconds or around 60 seconds, or they eventually fail. This can be elements from the same source, so it doesn't seem to be server specific at all.

Example: http://imgur.com/Hpq1b

This is the output I get from the proxy:


macwakko:grinder-3.7.1: wakko$ java -cp lib/grinder.jar net.grinder.TCPProxy -http -debug
PicoContainer: No component for key: interface net.grinder.plugin.http.tcpproxyfilter.HTTPFilterEventListener
PicoContainer: No component for key: interface net.grinder.plugin.http.tcpproxyfilter.ConnectionHandlerFactory
PicoContainer: No component for key: interface net.grinder.plugin.http.tcpproxyfilter.HTTPRecording
PicoContainer: No component for key: interface org.slf4j.Logger
PicoContainer: No component for key: interface net.grinder.plugin.http.tcpproxyfilter.RegularExpressions
PicoContainer: No component for key: interface net.grinder.util.http.URIParser
PicoContainer: No component for key: interface net.grinder.util.AttributeStringParser
PicoContainer: No component for key: interface net.grinder.util.StringEscaper
PicoContainer: No component for key: interface net.grinder.tools.tcpproxy.CommentSource
PicoContainer: No component for key: interface net.grinder.plugin.http.tcpproxyfilter.HTTPRecordingResultProcessor
PicoContainer: No component for key: interface org.slf4j.Logger
PicoContainer: No component for key: interface net.grinder.plugin.http.tcpproxyfilter.RegularExpressions
PicoContainer: No component for key: interface net.grinder.util.http.URIParser
PicoContainer: No component for key: class net.grinder.plugin.http.tcpproxyfilter.ProcessHTTPRecordingWithXSLT$BuiltInStyleSheet
PicoContainer: No component for key: class net.grinder.plugin.http.tcpproxyfilter.ProcessHTTPRecordingWithXSLT$StyleSheetFile
PicoContainer: No component for key: interface org.slf4j.Logger
PicoContainer: instantiating net.grinder.plugin.http.tcpproxyfilter.ProcessHTTPRecordingWithXSLT(java.io.PrintWriter, org.slf4j.Logger)
PicoContainer: instantiated net.grinder.plugin.http.tcpproxyfilter.ProcessHTTPRecordingWithXSLT(java.io.PrintWriter, org.slf4j.Logger) [3 ms], component net.grinder.plugin.http.tcpproxyfilter.ProcessHTTPRecordingWithXSLT, injected [java.io.PrintWriter, ch.qos.logback.classic.Logger]
PicoContainer: instantiating net.grinder.plugin.http.tcpproxyfilter.RegularExpressionsImplementation()
PicoContainer: instantiated net.grinder.plugin.http.tcpproxyfilter.RegularExpressionsImplementation() [2 ms], component net.grinder.plugin.http.tcpproxyfilter.RegularExpressionsImplementation, injected []
PicoContainer: instantiating net.grinder.util.http.URIParserImplementation()
PicoContainer: instantiated net.grinder.util.http.URIParserImplementation() [0 ms], component net.grinder.util.http.URIParserImplementation, injected []
PicoContainer: instantiating net.grinder.plugin.http.tcpproxyfilter.HTTPRecordingImplementation(net.grinder.plugin.http.tcpproxyfilter.HTTPRecordingResultProcessor, org.slf4j.Logger, net.grinder.plugin.http.tcpproxyfilter.RegularExpressions, net.grinder.util.http.URIParser)
PicoContainer: instantiated net.grinder.plugin.http.tcpproxyfilter.HTTPRecordingImplementation(net.grinder.plugin.http.tcpproxyfilter.HTTPRecordingResultProcessor, org.slf4j.Logger, net.grinder.plugin.http.tcpproxyfilter.RegularExpressions, net.grinder.util.http.URIParser) [155 ms], component net.grinder.plugin.http.tcpproxyfilter.HTTPRecordingImplementation, injected [net.grinder.plugin.http.tcpproxyfilter.ProcessHTTPRecordingWithXSLT, ch.qos.logback.classic.Logger, net.grinder.plugin.http.tcpproxyfilter.RegularExpressionsImplementation, net.grinder.util.http.URIParserImplementation]
PicoContainer: instantiating net.grinder.util.AttributeStringParserImplementation()
PicoContainer: instantiated net.grinder.util.AttributeStringParserImplementation() [0 ms], component net.grinder.util.AttributeStringParserImplementation, injected []
PicoContainer: instantiating net.grinder.util.SimpleStringEscaper()
PicoContainer: instantiated net.grinder.util.SimpleStringEscaper() [0 ms], component net.grinder.util.SimpleStringEscaper, injected []
PicoContainer: instantiating net.grinder.plugin.http.tcpproxyfilter.ConnectionHandlerFactoryImplementation(net.grinder.plugin.http.tcpproxyfilter.HTTPRecording, org.slf4j.Logger, net.grinder.plugin.http.tcpproxyfilter.RegularExpressions, net.grinder.util.http.URIParser, net.grinder.util.AttributeStringParser, net.grinder.util.StringEscaper, net.grinder.tools.tcpproxy.CommentSource)
PicoContainer: instantiated net.grinder.plugin.http.tcpproxyfilter.ConnectionHandlerFactoryImplementation(net.grinder.plugin.http.tcpproxyfilter.HTTPRecording, org.slf4j.Logger, net.grinder.plugin.http.tcpproxyfilter.RegularExpressions, net.grinder.util.http.URIParser, net.grinder.util.AttributeStringParser, net.grinder.util.StringEscaper, net.grinder.tools.tcpproxy.CommentSource) [0 ms], component net.grinder.plugin.http.tcpproxyfilter.ConnectionHandlerFactoryImplementation, injected [net.grinder.plugin.http.tcpproxyfilter.HTTPRecordingImplementation, ch.qos.logback.classic.Logger, net.grinder.plugin.http.tcpproxyfilter.RegularExpressionsImplementation, net.grinder.util.http.URIParserImplementation, net.grinder.util.AttributeStringParserImplementation, net.grinder.util.SimpleStringEscaper
 , net.grinder.tools.tcpproxy.CommentSourceImplementation]
PicoContainer: instantiating net.grinder.plugin.http.tcpproxyfilter.ConnectionCache(net.grinder.plugin.http.tcpproxyfilter.ConnectionHandlerFactory)
PicoContainer: instantiated net.grinder.plugin.http.tcpproxyfilter.ConnectionCache(net.grinder.plugin.http.tcpproxyfilter.ConnectionHandlerFactory) [0 ms], component net.grinder.plugin.http.tcpproxyfilter.ConnectionCache, injected [net.grinder.plugin.http.tcpproxyfilter.ConnectionHandlerFactoryImplementation]
PicoContainer: instantiating net.grinder.plugin.http.tcpproxyfilter.HTTPRequestFilter(net.grinder.plugin.http.tcpproxyfilter.HTTPFilterEventListener)
PicoContainer: instantiated net.grinder.plugin.http.tcpproxyfilter.HTTPRequestFilter(net.grinder.plugin.http.tcpproxyfilter.HTTPFilterEventListener) [0 ms], component net.grinder.plugin.http.tcpproxyfilter.HTTPRequestFilter, injected [net.grinder.plugin.http.tcpproxyfilter.ConnectionCache]
PicoContainer: No component for key: interface net.grinder.plugin.http.tcpproxyfilter.HTTPFilterEventListener
PicoContainer: instantiating net.grinder.plugin.http.tcpproxyfilter.HTTPResponseFilter(net.grinder.plugin.http.tcpproxyfilter.HTTPFilterEventListener)
PicoContainer: instantiated net.grinder.plugin.http.tcpproxyfilter.HTTPResponseFilter(net.grinder.plugin.http.tcpproxyfilter.HTTPFilterEventListener) [0 ms], component net.grinder.plugin.http.tcpproxyfilter.HTTPResponseFilter, injected [net.grinder.plugin.http.tcpproxyfilter.ConnectionCache]
2012-03-15 10:08:38,374 INFO  tcpproxy: Initialising as an HTTP/HTTPS proxy with the parameters:
   Request filters:    HTTPRequestFilter
   Response filters:   HTTPResponseFilter
   Local address:      localhost:8001
2012-03-15 10:08:38,577 INFO  tcpproxy: Engine initialised, listening on port 8001
2012-03-15 10:08:43,064 ERROR tcpproxy: Received fatal alert: unexpected_message
javax.net.ssl.SSLException: Received fatal alert: unexpected_message
        at com.sun.net.ssl.internal.ssl.Alerts.getSSLException(Alerts.java:190) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.Alerts.getSSLException(Alerts.java:136) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.recvAlert(SSLSocketImpl.java:1806) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:986) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.performInitialHandshake(SSLSocketImpl.java:1170) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.readDataRecord(SSLSocketImpl.java:785) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.AppInputStream.read(AppInputStream.java:75) ~[na:1.6]
        at net.grinder.tools.tcpproxy.AbstractTCPProxyEngine$FilteredStreamThread.interruptibleRun(AbstractTCPProxyEngine.java:431) ~[grinder-http-3.7.1.jar:na]
        at net.grinder.util.thread.InterruptibleRunnableAdapter.run(InterruptibleRunnableAdapter.java:58) [grinder-core-3.7.1.jar:na]
        at java.lang.Thread.run(Thread.java:680) [na:1.6.0_29]
2012-03-15 10:08:43,079 ERROR tcpproxy: Received fatal alert: unexpected_message
javax.net.ssl.SSLException: Received fatal alert: unexpected_message
        at com.sun.net.ssl.internal.ssl.Alerts.getSSLException(Alerts.java:190) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.Alerts.getSSLException(Alerts.java:136) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.recvAlert(SSLSocketImpl.java:1806) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:986) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.performInitialHandshake(SSLSocketImpl.java:1170) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.readDataRecord(SSLSocketImpl.java:785) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.AppInputStream.read(AppInputStream.java:75) ~[na:1.6]
        at net.grinder.tools.tcpproxy.AbstractTCPProxyEngine$FilteredStreamThread.interruptibleRun(AbstractTCPProxyEngine.java:431) ~[grinder-http-3.7.1.jar:na]
        at net.grinder.util.thread.InterruptibleRunnableAdapter.run(InterruptibleRunnableAdapter.java:58) [grinder-core-3.7.1.jar:na]
        at java.lang.Thread.run(Thread.java:680) [na:1.6.0_29]
2012-03-15 10:08:43,097 ERROR tcpproxy: Received fatal alert: unexpected_message
javax.net.ssl.SSLException: Received fatal alert: unexpected_message
        at com.sun.net.ssl.internal.ssl.Alerts.getSSLException(Alerts.java:190) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.Alerts.getSSLException(Alerts.java:136) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.recvAlert(SSLSocketImpl.java:1806) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:986) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.performInitialHandshake(SSLSocketImpl.java:1170) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.readDataRecord(SSLSocketImpl.java:785) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.AppInputStream.read(AppInputStream.java:75) ~[na:1.6]
        at net.grinder.tools.tcpproxy.AbstractTCPProxyEngine$FilteredStreamThread.interruptibleRun(AbstractTCPProxyEngine.java:431) ~[grinder-http-3.7.1.jar:na]
        at net.grinder.util.thread.InterruptibleRunnableAdapter.run(InterruptibleRunnableAdapter.java:58) [grinder-core-3.7.1.jar:na]
        at java.lang.Thread.run(Thread.java:680) [na:1.6.0_29]
2012-03-15 10:09:14,055 ERROR tcpproxy: Received fatal alert: unexpected_message
javax.net.ssl.SSLException: Received fatal alert: unexpected_message
        at com.sun.net.ssl.internal.ssl.Alerts.getSSLException(Alerts.java:190) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.Alerts.getSSLException(Alerts.java:136) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.recvAlert(SSLSocketImpl.java:1806) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:986) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.performInitialHandshake(SSLSocketImpl.java:1170) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.readDataRecord(SSLSocketImpl.java:785) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.AppInputStream.read(AppInputStream.java:75) ~[na:1.6]
        at net.grinder.tools.tcpproxy.AbstractTCPProxyEngine$FilteredStreamThread.interruptibleRun(AbstractTCPProxyEngine.java:431) ~[grinder-http-3.7.1.jar:na]
        at net.grinder.util.thread.InterruptibleRunnableAdapter.run(InterruptibleRunnableAdapter.java:58) [grinder-core-3.7.1.jar:na]
        at java.lang.Thread.run(Thread.java:680) [na:1.6.0_29]
2012-03-15 10:10:18,050 ERROR tcpproxy: Received fatal alert: unexpected_message
javax.net.ssl.SSLException: Received fatal alert: unexpected_message
        at com.sun.net.ssl.internal.ssl.Alerts.getSSLException(Alerts.java:190) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.Alerts.getSSLException(Alerts.java:136) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.recvAlert(SSLSocketImpl.java:1806) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:986) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.performInitialHandshake(SSLSocketImpl.java:1170) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.readDataRecord(SSLSocketImpl.java:785) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.AppInputStream.read(AppInputStream.java:75) ~[na:1.6]
        at net.grinder.tools.tcpproxy.AbstractTCPProxyEngine$FilteredStreamThread.interruptibleRun(AbstractTCPProxyEngine.java:431) ~[grinder-http-3.7.1.jar:na]
        at net.grinder.util.thread.InterruptibleRunnableAdapter.run(InterruptibleRunnableAdapter.java:58) [grinder-core-3.7.1.jar:na]
        at java.lang.Thread.run(Thread.java:680) [na:1.6.0_29]
2012-03-15 10:10:18,260 ERROR tcpproxy: Received fatal alert: unexpected_message
javax.net.ssl.SSLException: Received fatal alert: unexpected_message
        at com.sun.net.ssl.internal.ssl.Alerts.getSSLException(Alerts.java:190) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.Alerts.getSSLException(Alerts.java:136) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.recvAlert(SSLSocketImpl.java:1806) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:986) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.performInitialHandshake(SSLSocketImpl.java:1170) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.readDataRecord(SSLSocketImpl.java:785) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.AppInputStream.read(AppInputStream.java:75) ~[na:1.6]
        at net.grinder.tools.tcpproxy.AbstractTCPProxyEngine$FilteredStreamThread.interruptibleRun(AbstractTCPProxyEngine.java:431) ~[grinder-http-3.7.1.jar:na]
        at net.grinder.util.thread.InterruptibleRunnableAdapter.run(InterruptibleRunnableAdapter.java:58) [grinder-core-3.7.1.jar:na]
        at java.lang.Thread.run(Thread.java:680) [na:1.6.0_29]
2012-03-15 10:10:18,399 ERROR tcpproxy: Received fatal alert: unexpected_message
javax.net.ssl.SSLException: Received fatal alert: unexpected_message
        at com.sun.net.ssl.internal.ssl.Alerts.getSSLException(Alerts.java:190) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.Alerts.getSSLException(Alerts.java:136) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.recvAlert(SSLSocketImpl.java:1806) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:986) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.performInitialHandshake(SSLSocketImpl.java:1170) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.readDataRecord(SSLSocketImpl.java:785) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.AppInputStream.read(AppInputStream.java:75) ~[na:1.6]
        at net.grinder.tools.tcpproxy.AbstractTCPProxyEngine$FilteredStreamThread.interruptibleRun(AbstractTCPProxyEngine.java:431) ~[grinder-http-3.7.1.jar:na]
        at net.grinder.util.thread.InterruptibleRunnableAdapter.run(InterruptibleRunnableAdapter.java:58) [grinder-core-3.7.1.jar:na]
        at java.lang.Thread.run(Thread.java:680) [na:1.6.0_29]
2012-03-15 10:10:18,534 ERROR tcpproxy: java.lang.IllegalStateException: Internal error
javax.net.ssl.SSLException: java.lang.IllegalStateException: Internal error
        at com.sun.net.ssl.internal.ssl.Alerts.getSSLException(Alerts.java:190) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.fatal(SSLSocketImpl.java:1731) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.fatal(SSLSocketImpl.java:1692) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.handleException(SSLSocketImpl.java:1675) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.handleException(SSLSocketImpl.java:1601) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.AppInputStream.read(AppInputStream.java:86) ~[na:1.6]
        at net.grinder.tools.tcpproxy.AbstractTCPProxyEngine$FilteredStreamThread.interruptibleRun(AbstractTCPProxyEngine.java:431) ~[grinder-http-3.7.1.jar:na]
        at net.grinder.util.thread.InterruptibleRunnableAdapter.run(InterruptibleRunnableAdapter.java:58) [grinder-core-3.7.1.jar:na]
        at java.lang.Thread.run(Thread.java:680) [na:1.6.0_29]
Caused by: java.lang.IllegalStateException: Internal error
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.initHandshaker(SSLSocketImpl.java:1107) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:916) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.performInitialHandshake(SSLSocketImpl.java:1170) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.SSLSocketImpl.readDataRecord(SSLSocketImpl.java:785) ~[na:1.6]
        at com.sun.net.ssl.internal.ssl.AppInputStream.read(AppInputStream.java:75) ~[na:1.6]
        ... 3 common frames omitted


----------------------------------------------------------------------

>Comment By: Anders Storsveen (bushwakko)
Date: 2012-03-19 04:40

Message:
Tested with 1.3.8-SNAPSHOT from git, and it seems to work! Thank you!

All the urls except one, are wrong though, dunno why this is:

url0 = 'https://localhost:64831'
url1 = 'https://localhost:64835'
url2 = 'https://localhost:64836'
url3 = 'https://localhost:64837'
url4 = 'https://localhost:64838'
url5 = 'https://localhost:64839'
url6 = 'https://localhost:64840'
url7 = 'https://localhost:64853'
url8 = 'https://localhost:64855'
url9 = 'https://localhost:64856'
url10 = 'https://localhost:64858'
url11 = 'https://localhost:64859'
url12 = 'https://localhost:64860'
url13 = 'https://localhost:64861'
url14 = 'https://localhost:64870'
url15 = 'https://localhost:64877'
url16 = 'https://localhost:64880'
url17 = 'https://localhost:64881'
url18 = 'https://localhost:64882'
url19 = 'https://localhost:64886'
url20 = 'https://localhost:64887'
url21 = 'https://localhost:64888'
url22 = 'https://localhost:64889'
url23 = 'http://frontend.xstream.dk:80'
url24 = 'https://localhost:64903'
url25 = 'https://localhost:64904'

----------------------------------------------------------------------

Comment By: Philip Aston (philipa)
Date: 2012-03-19 04:40

Message:
Ah, sorry. Yes, you also need an updated xmlbeans jar (attached).

----------------------------------------------------------------------

Comment By: Anders Storsveen (bushwakko)
Date: 2012-03-19 04:21

Message:
Seems like this fix has some dependencies on some other changes as well:

macwakko:grinder-3.7.1: wakko$ java -cp lib/grinder.jar
net.grinder.TCPProxy -console -http
2012-03-19 12:20:10,467 ERROR tcpproxy: Could not initialise
java.lang.NoSuchMethodError:
net.grinder.plugin.http.xml.HTTPRecordingType$Metadata.setTestNumberOffset(I)V
	at
net.grinder.plugin.http.tcpproxyfilter.HTTPRecordingImplementation.<init>(HTTPRecordingImplementation.java:121)
~[grinder-http-3.7.1.jar:na]
	at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
~[na:1.6.0_29]
	at
sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
~[na:1.6.0_29]
	at
sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
~[na:1.6.0_29]
	at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
~[na:1.6.0_29]



----------------------------------------------------------------------

Comment By: Philip Aston (philipa)
Date: 2012-03-18 04:29

Message:
I believe I've fixed this:
http://grinder.git.sourceforge.net/git/gitweb.cgi?p=grinder/grinder;a=commitdiff;h=019e6d42bb7fe340ec5673915f8c2029b187f9e2

I'll attach a new grinder-http-3.7.1.jar to this bug. You can drop this
over the existing one. It will also include the pending TCPProxy fixes for
3471476, 3484390, 3475516.

Please give this a go and let me know how you get on.

Note, the attached jar will produce additional debug statements to stderr
during the recording. These will be disabled by default when the fix is
released in the next version of The Grinder.

----------------------------------------------------------------------

Comment By: Philip Aston (philipa)
Date: 2012-03-17 08:16

Message:
The good news is I can reproduce this.

It will take me a while to figure out what's going on however.

----------------------------------------------------------------------

Comment By: Philip Aston (philipa)
Date: 2012-03-16 11:56

Message:
The localhost connections are not unusual. There are several TCPProxyEngine
instances. The Grinder terminates the SSL connection from the browser with
one of them.

----------------------------------------------------------------------

Comment By: Anders Storsveen (bushwakko)
Date: 2012-03-15 07:13

Message:
I added the following debug output to AbstractTCPProxyEngine:

    /**
     * Main event loop.
     */
    @Override
    public void interruptibleRun() {

      m_outputStreamFilterTee.connectionOpened();

      final byte[] buffer = new byte[BUFFER_SIZE];

           
System.out.println(m_outputStreamFilterTee.m_connectionDetails.getConnectionIdentity()
+ " and "
                +
m_outputStreamFilterTee.getConnectionDetails().hashCode());



and got:




2012-03-15 15:04:14,461 INFO  tcpproxy: Engine initialised, listening on
port 8001
localhost:51498|snippets.mozilla.com:443|true and 727668954
localhost:51498|snippets.mozilla.com:443|true and 727668954
2012-03-15 15:04:18,292 ERROR tcpproxy: Received fatal alert:
access_denied
javax.net.ssl.SSLHandshakeException: Received fatal alert: access_denied
	at com.sun.net.ssl.internal.ssl.Alerts.getSSLException(Alerts.java:174)
~[na:1.6]
	at com.sun.net.ssl.internal.ssl.Alerts.getSSLException(Alerts.java:136)
~[na:1.6]
	at
com.sun.net.ssl.internal.ssl.SSLSocketImpl.recvAlert(SSLSocketImpl.java:1806)
~[na:1.6]
	at
com.sun.net.ssl.internal.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:986)
~[na:1.6]
	at
com.sun.net.ssl.internal.ssl.SSLSocketImpl.performInitialHandshake(SSLSocketImpl.java:1170)
~[na:1.6]
	at
com.sun.net.ssl.internal.ssl.SSLSocketImpl.readDataRecord(SSLSocketImpl.java:785)
~[na:1.6]
	at
com.sun.net.ssl.internal.ssl.AppInputStream.read(AppInputStream.java:75)
~[na:1.6]
	at
net.grinder.tools.tcpproxy.AbstractTCPProxyEngine$FilteredStreamThread.interruptibleRun(AbstractTCPProxyEngine.java:436)
~[grinder-http-3.8-SNAPSHOT.jar:na]
	at
net.grinder.util.thread.InterruptibleRunnableAdapter.run(InterruptibleRunnableAdapter.java:58)
[grinder-core-3.8-SNAPSHOT.jar:na]
	at java.lang.Thread.run(Thread.java:680) [na:1.6.0_29]
localhost:51501|staging.comoyo.no:443|true and -836403326
localhost:51501|staging.comoyo.no:443|true and -836403326
d2zl3c8ue8jcvu.cloudfront.net:443|localhost:51509|true and 680119289
d2zl3c8ue8jcvu.cloudfront.net:443|localhost:51509|true and 680119289
d2zl3c8ue8jcvu.cloudfront.net:443|localhost:51509|true and 680119289
d2zl3c8ue8jcvu.cloudfront.net:443|localhost:51509|true and 680119289
d2zl3c8ue8jcvu.cloudfront.net:443|localhost:51518|true and 1538993819
d2zl3c8ue8jcvu.cloudfront.net:443|localhost:51518|true and 1538993819
d2zl3c8ue8jcvu.cloudfront.net:443|localhost:51518|true and 1538993819
d2zl3c8ue8jcvu.cloudfront.net:443|localhost:51518|true and 1538993819
d2zl3c8ue8jcvu.cloudfront.net:443|localhost:51518|true and 1538993819
d2zl3c8ue8jcvu.cloudfront.net:443|localhost:51518|true and 1538993819
d2zl3c8ue8jcvu.cloudfront.net:443|localhost:51523|true and -2011615551
d2zl3c8ue8jcvu.cloudfront.net:443|localhost:51523|true and -2011615551
2012-03-15 15:04:22,366 ERROR tcpproxy: Received fatal alert:
unexpected_message
javax.net.ssl.SSLException: Received fatal alert: unexpected_message
	at com.sun.net.ssl.internal.ssl.Alerts.getSSLException(Alerts.java:190)
~[na:1.6]
	at com.sun.net.ssl.internal.ssl.Alerts.getSSLException(Alerts.java:136)
~[na:1.6]
	at
com.sun.net.ssl.internal.ssl.SSLSocketImpl.recvAlert(SSLSocketImpl.java:1806)
~[na:1.6]
	at
com.sun.net.ssl.internal.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:986)
~[na:1.6]
	at
com.sun.net.ssl.internal.ssl.SSLSocketImpl.performInitialHandshake(SSLSocketImpl.java:1170)
~[na:1.6]
	at
com.sun.net.ssl.internal.ssl.SSLSocketImpl.readDataRecord(SSLSocketImpl.java:785)
~[na:1.6]
	at
com.sun.net.ssl.internal.ssl.AppInputStream.read(AppInputStream.java:75)
~[na:1.6]
	at
net.grinder.tools.tcpproxy.AbstractTCPProxyEngine$FilteredStreamThread.interruptibleRun(AbstractTCPProxyEngine.java:436)
~[grinder-http-3.8-SNAPSHOT.jar:na]
	at
net.grinder.util.thread.InterruptibleRunnableAdapter.run(InterruptibleRunnableAdapter.java:58)
[grinder-core-3.8-SNAPSHOT.jar:na]
	at java.lang.Thread.run(Thread.java:680) [na:1.6.0_29]
d2zl3c8ue8jcvu.cloudfront.net:443|localhost:51523|true and -2011615551
d2zl3c8ue8jcvu.cloudfront.net:443|localhost:51523|true and -2011615551
2012-03-15 15:04:22,387 ERROR tcpproxy: Received fatal alert:
unexpected_message
javax.net.ssl.SSLException: Received fatal alert: unexpected_message


and strangely i found this in the http recording:


url0 = 'https://localhost:51501'


This seems a little strange, since there is nothing in the webpage that
points to localhost, so it looks like wires are getting crossed somewhere
in the code....

----------------------------------------------------------------------

Comment By: Anders Storsveen (bushwakko)
Date: 2012-03-15 04:50

Message:
Found a way to get some ssl debug info:

http://pastebin.com/mwi3fAXu

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=118598&aid=3505060&group_id=18598

------------------------------------------------------------------------------
This SF email is sponsosred by:
Try Windows Azure free for 90 days Click Here 
http://p.sf.net/sfu/sfd2d-msazure