Skip to content
This repository has been archived by the owner on Nov 27, 2020. It is now read-only.

TLSv1.2 issue #728

Closed
pankajgambhir opened this issue Jan 31, 2016 · 6 comments
Closed

TLSv1.2 issue #728

pankajgambhir opened this issue Jan 31, 2016 · 6 comments

Comments

@pankajgambhir
Copy link

Hi

We are using capybara+poltergeist+PhantomJS, we were enjoying the whole experience and recently PayPal made a change at their end enforcing everyone to use TLSv1.2, so my local tests (Mac OS X) stopped working (this is the url where i try to connect to which gives SSL handshake failure - https://www.sandbox.paypal.com). But the same tests run fine on Jenkins, so I am having a real hard time figuring out what could be wrong in my local or what is different from Jenkins, could you please share any tips or suggestions?

thanks a ton!

Regards
Pankaj

@route
Copy link
Contributor

route commented Jan 31, 2016

Hi Pankaj, phantomjs/poltergeist/capybara versions and a part of log are appreciated.

@pankajgambhir
Copy link
Author

Thanks for the response, below is the info you asked for:

phantomjs 1.9.8.0
poltergeist 1.8.1
capybara 2-6
mac os yosemite 10.10.5

LOG:
2016-01-27T17:37:27 [DEBUG] CookieJar - Created but will not store cookies (use option '--cookies-file=' to enable persisten cookie storage)
2016-01-27T17:37:27 [DEBUG] Phantom - execute: Configuration
2016-01-27T17:37:27 [DEBUG] 0 objectName : ""
2016-01-27T17:37:27 [DEBUG] 1 cookiesFile : ""
2016-01-27T17:37:27 [DEBUG] 2 diskCacheEnabled : "false"
2016-01-27T17:37:27 [DEBUG] 3 maxDiskCacheSize : "-1"
2016-01-27T17:37:27 [DEBUG] 4 ignoreSslErrors : "true"
2016-01-27T17:37:27 [DEBUG] 5 localToRemoteUrlAccessEnabled : "false"
2016-01-27T17:37:27 [DEBUG] 6 outputEncoding : "UTF-8"
2016-01-27T17:37:27 [DEBUG] 7 proxyType : "http"
2016-01-27T17:37:27 [DEBUG] 8 proxy : ":1080"
2016-01-27T17:37:27 [DEBUG] 9 proxyAuth : ":"
2016-01-27T17:37:27 [DEBUG] 10 scriptEncoding : "UTF-8"
2016-01-27T17:37:27 [DEBUG] 11 webSecurityEnabled : "false"
2016-01-27T17:37:27 [DEBUG] 12 offlineStoragePath : ""
2016-01-27T17:37:27 [DEBUG] 13 offlineStorageDefaultQuota : "-1"
2016-01-27T17:37:27 [DEBUG] 14 printDebugMessages : "true"
2016-01-27T17:37:27 [DEBUG] 15 javascriptCanOpenWindows : "true"
2016-01-27T17:37:27 [DEBUG] 16 javascriptCanCloseWindows : "true"
2016-01-27T17:37:27 [DEBUG] 17 sslProtocol : "any"
2016-01-27T17:37:27 [DEBUG] 18 sslCertificatesPath : ""
2016-01-27T17:37:27 [DEBUG] 19 webdriver : ":"
2016-01-27T17:37:27 [DEBUG] 20 webdriverLogFile : ""
2016-01-27T17:37:27 [DEBUG] 21 webdriverLogLevel : "INFO"
2016-01-27T17:37:27 [DEBUG] 22 webdriverSeleniumGridHub : ""
2016-01-27T17:37:27 [DEBUG] Phantom - execute: Script & Arguments
2016-01-27T17:37:27 [DEBUG] script: "/Users/gallagher/.rbenv/versions/2.2.2/lib/ruby/gems/2.2.0/gems/poltergeist-1.8.1/lib/capybara/poltergeist/client/compiled/main.js"
2016-01-27T17:37:27 [DEBUG] 0 arg: "55066"
2016-01-27T17:37:27 [DEBUG] 1 arg: "1024"
2016-01-27T17:37:27 [DEBUG] 2 arg: "768"
2016-01-27T17:37:27 [DEBUG] Phantom - execute: Starting normal mode
2016-01-27T17:37:27 [DEBUG] WebPage - setupFrame ""
2016-01-27T17:37:27 [DEBUG] FileSystem - _open: ":/modules/fs.js" QMap(("mode", QVariant(QString, "r") ) )
2016-01-27T17:37:27 [DEBUG] FileSystem - _open: ":/modules/system.js" QMap(("mode", QVariant(QString, "r") ) )
2016-01-27T17:37:27 [DEBUG] FileSystem - _open: ":/modules/_coffee-script.js" QMap(("mode", QVariant(QString, "r") ) )
2016-01-27T17:37:27 [DEBUG] FileSystem - _open: ":/modules/../coffee-script/package.json" QMap(("mode", QVariant(QString, "r") ) )
2016-01-27T17:37:27 [DEBUG] FileSystem - _open: ":/modules/../coffee-script/./lib/coffee-script/coffee-script.js" QMap(("mode", QVariant(QString, "r") ) )
2016-01-27T17:37:27 [DEBUG] FileSystem - _open: ":/modules/../coffee-script/./lib/coffee-script/./lexer.js" QMap(("mode", QVariant(QString, "r") ) )
2016-01-27T17:37:27 [DEBUG] FileSystem - _open: ":/modules/../coffee-script/./lib/coffee-script/././rewriter.js" QMap(("mode", QVariant(QString, "r") ) )
2016-01-27T17:37:27 [DEBUG] FileSystem - _open: ":/modules/../coffee-script/./lib/coffee-script/././helpers.js" QMap(("mode", QVariant(QString, "r") ) )
2016-01-27T17:37:27 [DEBUG] FileSystem - _open: ":/modules/../coffee-script/./lib/coffee-script/./parser.js" QMap(("mode", QVariant(QString, "r") ) )
2016-01-27T17:37:27 [DEBUG] FileSystem - _open: ":/modules/../coffee-script/./lib/coffee-script/./helpers.js" QMap(("mode", QVariant(QString, "r") ) )
2016-01-27T17:37:27 [DEBUG] FileSystem - _open: ":/modules/../coffee-script/./lib/coffee-script/./nodes.js" QMap(("mode", QVariant(QString, "r") ) )
2016-01-27T17:37:27 [DEBUG] FileSystem - _open: ":/modules/../coffee-script/./lib/coffee-script/././scope.js" QMap(("mode", QVariant(QString, "r") ) )
2016-01-27T17:37:27 [DEBUG] FileSystem - _open: ":/modules/../coffee-script/./lib/coffee-script/./././helpers.js" QMap(("mode", QVariant(QString, "r") ) )
2016-01-27T17:37:27 [DEBUG] FileSystem - _open: ":/modules/../coffee-script/./lib/coffee-script/././lexer.js" QMap(("mode", QVariant(QString, "r") ) )
2016-01-27T17:37:27 [DEBUG] FileSystem - _open: ":/modules/../coffee-script/./lib/coffee-script/./././rewriter.js" QMap(("mode", QVariant(QString, "r") ) )
2016-01-27T17:37:27 [DEBUG] FileSystem - _open: ":/modules/webpage.js" QMap(("mode", QVariant(QString, "r") ) )
2016-01-27T17:37:27 [DEBUG] Phantom - injectJs: "/Users/gallagher/.rbenv/versions/2.2.2/lib/ruby/gems/2.2.0/gems/poltergeist-1.8.1/lib/capybara/poltergeist/client/compiled/web_page.js"
2016-01-27T17:37:27 [DEBUG] Phantom - injectJs: "/Users/gallagher/.rbenv/versions/2.2.2/lib/ruby/gems/2.2.0/gems/poltergeist-1.8.1/lib/capybara/poltergeist/client/compiled/node.js"
2016-01-27T17:37:27 [DEBUG] Phantom - injectJs: "/Users/gallagher/.rbenv/versions/2.2.2/lib/ruby/gems/2.2.0/gems/poltergeist-1.8.1/lib/capybara/poltergeist/client/compiled/connection.js"
2016-01-27T17:37:27 [DEBUG] Phantom - injectJs: "/Users/gallagher/.rbenv/versions/2.2.2/lib/ruby/gems/2.2.0/gems/poltergeist-1.8.1/lib/capybara/poltergeist/client/compiled/cmd.js"
2016-01-27T17:37:27 [DEBUG] Phantom - injectJs: "/Users/gallagher/.rbenv/versions/2.2.2/lib/ruby/gems/2.2.0/gems/poltergeist-1.8.1/lib/capybara/poltergeist/client/compiled/browser.js"
2016-01-27T17:37:27 [DEBUG] WebpageCallbacks - getJsConfirmCallback
2016-01-27T17:37:27 [DEBUG] WebpageCallbacks - getJsConfirmCallback
2016-01-27T17:37:27 [DEBUG] WebPage - updateLoadingProgress: 10
2016-01-27T17:37:27 [DEBUG] Network - Resource request error: 6 ( "SSL handshake failed" ) URL: "https://www.sandbox.paypal.com/cgi-bin/webscr?cmd=_express-checkout&token=EC-8G369747A6828630R"
2016-01-27T17:37:27 [DEBUG] WebPage - updateLoadingProgress: 100
2016-01-27T17:37:27 [DEBUG] WebPage - setupFrame ""
2016-01-27T17:37:27 [DEBUG] WebPage - setupFrame ""
2016-01-27T17:37:27 [DEBUG] WebPage - evaluateJavaScript "(function() { return (function () {
return typeof __poltergeist;
})(); })()"
2016-01-27T17:37:27 [DEBUG] WebPage - evaluateJavaScript result QVariant(QString, "undefined")

@johncalvinyoung
Copy link

I believe PhantomJS 1.9.8 may have some real issues with TLS:
ariya/phantomjs#12165
ariya/phantomjs#13496

Your Jenkins server may have 2.0/2.1 installed, perhaps? Or it may be related to the version of openssl available on the system.

@pankajgambhir
Copy link
Author

Only difference was openssl version in local vs Jenkins but even after upgrading to same openssl version in local (Mac), we get error but not in Jenkins (Linux). so still stuck right now.

@twalpole
Copy link
Contributor

upgrade to phantomjs 2.1.x and make sure your phantomjs_options --ssl-protocol/--ssl-ciphersl are set correctly for whatever version you need

@twalpole
Copy link
Contributor

Closing due to age and lack of response

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants