Secure Connection Failed#903

Subscribe to Secure Connection Failed 6 post(s), 3 voice(s)

 
Avatar James O'Sull... 6 post(s) #2415

I’ve been trialing Twist and I’ve impressed so far. My Java experience is limited, but my primary language (C#) is enough like it for me to get up and running quickly.

My initial Twist project is using Selenium and Firefox and I’ve just switched over one of my tests from using HTTP to HTTPS, but I’m now getting the following issue:

[my server name] uses an invalid security certificate.

The certificate is not trusted because the issuer certificate has expired.

(Error code: sec_error_expired_issuer_certificate)

When I try to add an exception, the certificate that it’s trying to use isn’t the correct certificate. It appears to be signed by CyberVillainsCA.

Note: I’m using a self signed certificate.

Any ideas?

Thanks

 
Avatar Vivek Prahlad Administrator 2 post(s) #2419

James, thanks for trying out Twist!

Under the covers, Selenium uses javascript to control the browser, and that means that for every web page served, the HTTP response has to be modified in order to inject Selenium’s javascript code.

Now HTTPS is designed to prevent the response from being modifed in any way, so the Selenium server generates dummy certificates. The Cybervillains certificate is actually bundled with Selenium. When Selenium is run in proxy injection mode, all HTTP / HTTPS requests are routed via the Selenium proxy server.

Basically, it is down to two choices:
a. If you’re using proxy injection mode, then the CyberVillains certificate will need to be imported, or, (the downside is that this is a potential security risk, do take a look at this page from the Selenium documentation).
b. If you’re not using proxy injection mode, then the Chrome option (which essentailly launches Firefox with elevated security privileges) should work.

(BTW, in case you’re using Twist’s recorder, the recorder currently works with Firefox in proxy injection mode)

Hope this helps!

 
Avatar James O'Sull... 6 post(s) #2427

Thanks for the explanation Vivek. We are going to be using the recorder in part, so I’ll check out the certificate work around.

Out of interest are there plans to make the recorder work with Chrome?

 
Avatar Ketan Padega... 11 post(s) #2441

James,

As of now, there are no plans to add recording support for more browsers.

Just out of curiosity, why do you wish to record using chrome? Selenium does allow you to run the recorded code on multiple browsers. Am I missing something here ?

 
Avatar James O'Sull... 6 post(s) #2483

Ketan,
The thought of using Chrome for recording was based on the information Vivek supplied about the potential security risk of importing the CyberVillians certificate.

For the time-being we’ve chosen not to test over HTTPS.

With regards to using multiple browsers, I definitely would like to be able to do that. I didn’t see a way to set that up in Twist.

 
Avatar Ketan Padega... 11 post(s) #2485

James,

Using a different browser would involve changing the properties in the file “twist.properties”. This should be visible in the source directory.

We’re working on making this more usable in the future releases.