# Selenium, secure connection failed, security certificate

**URL:** <https://www.ruby-forum.com/t/selenium-secure-connection-failed-security-certificate/171592>\
**Category:** Ruby\
**Created:** [July 6, 2009, 11:47am UTC](https://www.ruby-forum.com/t/selenium-secure-connection-failed-security-certificate/171592 "2009-07-06T11:47:20Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![kga85](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/k/90ced4/32.png) [@kga85](https://www.ruby-forum.com/u/kga85)\
**Post date:** [July 6, 2009, 11:47am UTC](https://www.ruby-forum.com/t/selenium-secure-connection-failed-security-certificate/171592/1 "2009-07-06T11:47:20Z")

</div>

I am doing some testing with Selenium, and i have a problem.

The site I am testing is a secure site with username and password. And i  
have one problem. When i start Selenium tests from a ruby program then a  
new browser is opened, and this browser is cleen like a freshly  
installed firefox browser.

My problem is that the site I am testing gives this error:

Secure Connection Failed  
xxx uses an invalid security certificate.  
The certificate is not trusted because the issuer certificate is  
unknown.  
The certificate is only valid for xxx

(Error code: sec\_error\_unknown\_issuer)

This stops my test and i also has to accept this every time, it wont  
remember that I acceptet it earlyer because it always starts a fresh  
cleen firefox browser.

Is there a way to start the regular browser insted. A browser that  
remember that i have acceptet this before?

When i start the test from the Selenium IDE then it uses my regular  
browser: I want it to use my regular browser when I start it from a ruby  
program to. How do I do that?

---

<div class="post-metadata">

**Author:** ![kga85](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/k/90ced4/32.png) [@kga85](https://www.ruby-forum.com/u/kga85)\
**Post date:** [February 23, 2010, 10:44pm UTC](https://www.ruby-forum.com/t/selenium-secure-connection-failed-security-certificate/171592/2 "2010-02-23T22:44:20Z")

</div>

Kga A. wrote:

> I am doing some testing with Selenium, and i have a problem.  
> The site I am testing is a secure site with username and password. And i  
> have one problem. When i start Selenium tests from a ruby program then a  
> new browser is opened, and this browser is cleen like a freshly  
> installed firefox browser.  
> My problem is that the site I am testing gives this error:  
> Secure Connection Failed  
> xxx uses an invalid security certificate.  
> The certificate is not trusted because the issuer certificate is  
> unknown.  
> The certificate is only valid for xxx  
> (Error code: sec\_error\_unknown\_issuer)  
> This stops my test and i also has to accept this every time, it wont  
> remember that I acceptet it earlyer because it always starts a fresh  
> cleen firefox browser.  
> Is there a way to start the regular browser insted. A browser that  
> remember that i have acceptet this before?  
> When i start the test from the Selenium IDE then it uses my regular  
> browser: I want it to use my regular browser when I start it from a ruby  
> program to. How do I do that?

Has somebody actually posted a solution for this problem? I an  
experiencing exactkly the same thing

---

<div class="post-metadata">

**Author:** ![kga85](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/k/90ced4/32.png) [@kga85](https://www.ruby-forum.com/u/kga85)\
**Post date:** [February 24, 2010, 7:19am UTC](https://www.ruby-forum.com/t/selenium-secure-connection-failed-security-certificate/171592/3 "2010-02-24T07:19:56Z")

</div>

Hi,

Have you tried this solution →

[http://groups.google.com/group/selenium-ruby/browse\_thread/thread/2de7c8518d558f6c/0e1c7cf3866f15f8?fwc=1](http://groups.google.com/group/selenium-ruby/browse_thread/thread/2de7c8518d558f6c/0e1c7cf3866f15f8?fwc=1)

The solution is,

Yes. We can able to set the predefined profile.

When start the Selenium RC → mention ur profile details like this

> java -jar selenium-server.jar -firefoxProfileTemplate “C:\Documents and Settings\Administrator\Application Data\Mozilla\Firefox\Profiles\4sdo3eff.default”

---

<div class="post-metadata">

**Author:** ![kga85](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/k/90ced4/32.png) [@kga85](https://www.ruby-forum.com/u/kga85)\
**Post date:** [February 25, 2010, 7:50pm UTC](https://www.ruby-forum.com/t/selenium-secure-connection-failed-security-certificate/171592/4 "2010-02-25T19:50:36Z")

</div>

Raveendran .P wrote:

> Hi,
> 
> Have you tried this solution →
> 
> [http://groups.google.com/group/selenium-ruby/browse\_thread/thread/2de7c8518d558f6c/0e1c7cf3866f15f8?fwc=1](http://groups.google.com/group/selenium-ruby/browse_thread/thread/2de7c8518d558f6c/0e1c7cf3866f15f8?fwc=1)
> 
> The solution is,
> 
> Yes. We can able to set the predefined profile.
> 
> When start the Selenium RC → mention ur profile details like this
> 
> > java -jar selenium-server.jar -firefoxProfileTemplate “C:\Documents and Settings\Administrator\Application Data\Mozilla\Firefox\Profiles\4sdo3eff.default”

Thanks Raveendran, setting a special firefox profile for Selenium RC to  
use worked!  
How about IE? Are there any tricks to go around cert warnings in IE?
