Thursday, 17 October 2013

Disable 'Untrusted connection | SSL certificate' Warning

No need of custom Firefox|Chrome profiles to deal with "Untrusted connection" on Webdriver.

DesiredCapabilities capabilities = new DesiredCapabilities();
capabilities.setCapability(CapabilityType.ACCEPT_SSL_CERTS, true);
driver = new FirefoxDriver(capabilities);

Note: By default 'Untrusted connection | SSL certificate' will be disabled.



2 comments:

  1. we can also use below code....
    FirefoxProfile profile=new FirefoxProfile();
    profile.setAssumeUntrustedCertificateIssuer(false);
    WebDriver driver=new FirefoxDriver(profile);
    driver.get("ur required URl")

    ReplyDelete
  2. Thanks for the great information in your blog Selenium Training in Chennai

    ReplyDelete