You might be able to do this in a BeanShell test element, as this
allow you to run arbitrary Java code.

------- snip -----------
import javax.net.ssl.SSLSocket;
import javax.net.ssl.SSLSocketFactory;

String HTTPS_SERVER = ""; // Not sure what this is supposed to be

print("Setting SSLv3");

SSLSocket socket = (SSLSocket)
    SSLSocketFactory.getDefault().createSocket(
        HTTPS_SERVER.substring("https://".length()), 443);

socket.setEnabledProtocols(new String[] {"SSLv3"});

print("Finished setting SSLv3");

--------- snip ------------------

Put this in a BeanSHell sampler, in a separate Thread Group, and run
the sample once. Then run the rest of the test.

Or you could put the code in an initialisation file, in which case you
just need to ensure that the BeanShell element is called at least once
before the rest of the test.

The code could perhaps be added as an option for JMeter (e.g. via  a
property); feel free to create a Bugzilla enhancement request.

S.
On 22/05/06, Gaël LHEZ <[EMAIL PROTECTED]> wrote:
I finally found why my test does not run with https server :

This is due to the server, java, and client authentification : I do not own
a certificate, nor I want to.

I ran a sample socket test, to check that :


   SSLSocket socket = (SSLSocket)
SSLSocketFactory.getDefault().createSocket(
       HTTPS_SERVER.substring("https://".length()), 443);
//    socket.setEnabledProtocols(new String[] {
//      "SSLv3"
//    });
   socket.startHandshake();
   socket.getOutputStream().write("GET /
HTTP/1.0\r\n\r\n".getBytes("ASCII"));
   Scanner sc = new Scanner(socket.getInputStream());
   System.out.println(">>>");
   while (sc.hasNextLine())
     System.out.println(sc.nextLine());
   System.out.println("<<<");


That don't work untill I uncomment the commented lines.



Now, that I figured the problem, I'd like to fix it and I don't find any
proper way to disable TSL1.0 (which fails) :

Setting https.protocols won't help (tested, and failed)

Is there a way to specifiate that I want to use SSLv3, not TLS in jmeter?
(except from running deep into the code)



---------------------------------------------------------------------
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]

Reply via email to