Sauce连接Protractor-Cucumber抛出SSL验证错误

时间:2016-07-28 15:24:04

标签: ssl protractor ssl-certificate saucelabs cucumberjs

尝试通过Sauce Connect在Sauce Labs上运行Protractor-Cucumber测试。

在使用命令sc -u <username> -k启动sauce连接隧道exe时,我收到错误  'SSL verify error:num=20:unable to get local issuer certificate:depth=2...'

我最初使用 -

设置代理设置
npm config set proxy <proxy addr..>
npm config set https-proxy <proxy addr..>
set HTTP_PROXY=<proxy addr..>
set HTTPS_PROXY=<proxy addr..>

我在这里做错了什么

Sauce Connect Doctor的输出 -

28 Jul 15:36:15 - Sauce Connect 4.3.16, build 2397 a59c79b
28 Jul 15:36:15 - Calling the doctor
INFO: checking if saucelabs.com can be resolved
INFO: resolving 'saucelabs.com' using default system settings...
INFO: can't resolve 'saucelabs.com'
INFO: resolving 'saucelabs.com' using DNS server '10.7.12.7'...
INFO: can't resolve 'saucelabs.com' via DNS server '10.7.12.7'
!!! WARNING: DNS server '10.7.12.7' can NOT resolve 'saucelabs.com'.
!!! WARNING: this will make Sauce Connect unreliable.
INFO: resolving 'saucelabs.com' using DNS server '10.20.220.36'...
INFO: can't resolve 'saucelabs.com' via DNS server '10.20.220.36'
!!! WARNING: DNS server '10.20.220.36' can NOT resolve 'saucelabs.com'.
!!! WARNING: this will make Sauce Connect unreliable.
INFO: resolving 'saucelabs.com' using DNS server '8.8.8.8'...
INFO: can't resolve 'saucelabs.com'
INFO: resolving 'saucelabs.com' using DNS server '8.8.4.4'...
INFO: can't resolve 'saucelabs.com'
INFO: checking 'saucelabs.com' in hosts file...
INFO: 'saucelabs.com' is not in hosts file
INFO: checking if maki76100.miso.saucelabs.com can be resolved
INFO: resolving 'maki76100.miso.saucelabs.com' using default system settings...
INFO: can't resolve 'maki76100.miso.saucelabs.com'
INFO: resolving 'maki76100.miso.saucelabs.com' using DNS server '10.7.12.7'...
INFO: can't resolve 'maki76100.miso.saucelabs.com' via DNS server '10.7.12.7'
!!! WARNING: DNS server '10.7.12.7' can NOT resolve 'maki76100.miso.saucelabs.com'.
!!! WARNING: this will make Sauce Connect unreliable.
INFO: resolving 'maki76100.miso.saucelabs.com' using DNS server '10.20.220.36'...
INFO: can't resolve 'maki76100.miso.saucelabs.com' via DNS server '10.20.220.36'
!!! WARNING: DNS server '10.20.220.36' can NOT resolve 'maki76100.miso.saucelabs.com'.
!!! WARNING: this will make Sauce Connect unreliable.
INFO: resolving 'maki76100.miso.saucelabs.com' using DNS server '8.8.8.8'...
INFO: can't resolve 'maki76100.miso.saucelabs.com'
INFO: resolving 'maki76100.miso.saucelabs.com' using DNS server '8.8.4.4'...
INFO: can't resolve 'maki76100.miso.saucelabs.com'
INFO: checking 'maki76100.miso.saucelabs.com' in hosts file...
INFO: 'maki76100.miso.saucelabs.com' is not in hosts file
INFO: checking if maki77100.miso.saucelabs.com can be resolved
INFO: resolving 'maki77100.miso.saucelabs.com' using default system settings...
INFO: can't resolve 'maki77100.miso.saucelabs.com'
INFO: resolving 'maki77100.miso.saucelabs.com' using DNS server '10.7.12.7'...
INFO: can't resolve 'maki77100.miso.saucelabs.com' via DNS server '10.7.12.7'
!!! WARNING: DNS server '10.7.12.7' can NOT resolve 'maki77100.miso.saucelabs.com'.
!!! WARNING: this will make Sauce Connect unreliable.
INFO: resolving 'maki77100.miso.saucelabs.com' using DNS server '10.20.220.36'...
INFO: can't resolve 'maki77100.miso.saucelabs.com' via DNS server '10.20.220.36'
!!! WARNING: DNS server '10.20.220.36' can NOT resolve 'maki77100.miso.saucelabs.com'.
!!! WARNING: this will make Sauce Connect unreliable.
INFO: resolving 'maki77100.miso.saucelabs.com' using DNS server '8.8.8.8'...
INFO: can't resolve 'maki77100.miso.saucelabs.com'
INFO: resolving 'maki77100.miso.saucelabs.com' using DNS server '8.8.4.4'...
INFO: can't resolve 'maki77100.miso.saucelabs.com'
INFO: checking 'maki77100.miso.saucelabs.com' in hosts file...
INFO: 'maki77100.miso.saucelabs.com' is not in hosts file
INFO: checking if maki78100.miso.saucelabs.com can be resolved
INFO: resolving 'maki78100.miso.saucelabs.com' using default system settings...
INFO: can't resolve 'maki78100.miso.saucelabs.com'
INFO: resolving 'maki78100.miso.saucelabs.com' using DNS server '10.7.12.7'...
INFO: can't resolve 'maki78100.miso.saucelabs.com' via DNS server '10.7.12.7'
!!! WARNING: DNS server '10.7.12.7' can NOT resolve 'maki78100.miso.saucelabs.com'.
!!! WARNING: this will make Sauce Connect unreliable.
INFO: resolving 'maki78100.miso.saucelabs.com' using DNS server '10.20.220.36'...
INFO: can't resolve 'maki78100.miso.saucelabs.com' via DNS server '10.20.220.36'
!!! WARNING: DNS server '10.20.220.36' can NOT resolve 'maki78100.miso.saucelabs.com'.
!!! WARNING: this will make Sauce Connect unreliable.
INFO: resolving 'maki78100.miso.saucelabs.com' using DNS server '8.8.8.8'...
INFO: can't resolve 'maki78100.miso.saucelabs.com'
INFO: resolving 'maki78100.miso.saucelabs.com' using DNS server '8.8.4.4'...
INFO: can't resolve 'maki78100.miso.saucelabs.com'
INFO: checking 'maki78100.miso.saucelabs.com' in hosts file...
INFO: 'maki78100.miso.saucelabs.com' is not in hosts file
!!! ERROR: can't resolve 3/3 tunnel hostname(s) via any DNS server.
!!! ERROR: please check your firewall and DNS settings.
INFO: checking if connecting to Sauce Labs REST API via SSL works
!!! ERROR: SSL connect failed, socket: 908, code: 5.
INFO: checking if accessing https://saucelabs.com/rest/v1 works
INFO: resolving 'saucelabs.com' using default system settings...
INFO: can't resolve 'saucelabs.com'
INFO: resolving 'saucelabs.com' using DNS server '10.7.12.7'...
INFO: can't resolve 'saucelabs.com' via DNS server '10.7.12.7'
!!! WARNING: DNS server '10.7.12.7' can NOT resolve 'saucelabs.com'.
!!! WARNING: this will make Sauce Connect unreliable.
INFO: resolving 'saucelabs.com' using DNS server '10.20.220.36'...
INFO: can't resolve 'saucelabs.com' via DNS server '10.20.220.36'
!!! WARNING: DNS server '10.20.220.36' can NOT resolve 'saucelabs.com'.
!!! WARNING: this will make Sauce Connect unreliable.
INFO: resolving 'saucelabs.com' using DNS server '8.8.8.8'...
INFO: can't resolve 'saucelabs.com'
INFO: resolving 'saucelabs.com' using DNS server '8.8.4.4'...
INFO: can't resolve 'saucelabs.com'
INFO: checking 'saucelabs.com' in hosts file...
INFO: 'saucelabs.com' is not in hosts file
INFO: URL https://saucelabs.com/versions.json can be reached
INFO: resolving 'saucelabs.com' using default system settings...
INFO: can't resolve 'saucelabs.com'
INFO: resolving 'saucelabs.com' using DNS server '10.7.12.7'...
INFO: can't resolve 'saucelabs.com' via DNS server '10.7.12.7'
!!! WARNING: DNS server '10.7.12.7' can NOT resolve 'saucelabs.com'.
!!! WARNING: this will make Sauce Connect unreliable.
INFO: resolving 'saucelabs.com' using DNS server '10.20.220.36'...
INFO: can't resolve 'saucelabs.com' via DNS server '10.20.220.36'
!!! WARNING: DNS server '10.20.220.36' can NOT resolve 'saucelabs.com'.
!!! WARNING: this will make Sauce Connect unreliable.
INFO: resolving 'saucelabs.com' using DNS server '8.8.8.8'...
INFO: can't resolve 'saucelabs.com'
INFO: resolving 'saucelabs.com' using DNS server '8.8.4.4'...
INFO: can't resolve 'saucelabs.com'
INFO: checking 'saucelabs.com' in hosts file...
INFO: 'saucelabs.com' is not in hosts file
INFO: URL https://saucelabs.com/rest/v1/myuserid/tunnels can be reached
INFO: checking if accessing http://google.com works
INFO: resolving 'google.com' using default system settings...
INFO: can't resolve 'google.com'
INFO: resolving 'google.com' using DNS server '10.7.12.7'...
INFO: can't resolve 'google.com' via DNS server '10.7.12.7'
!!! WARNING: DNS server '10.7.12.7' can NOT resolve 'google.com'.
!!! WARNING: this will make Sauce Connect unreliable.
INFO: resolving 'google.com' using DNS server '10.20.220.36'...
INFO: can't resolve 'google.com' via DNS server '10.20.220.36'
!!! WARNING: DNS server '10.20.220.36' can NOT resolve 'google.com'.
!!! WARNING: this will make Sauce Connect unreliable.
INFO: resolving 'google.com' using DNS server '8.8.8.8'...
INFO: can't resolve 'google.com'
INFO: resolving 'google.com' using DNS server '8.8.4.4'...
INFO: can't resolve 'google.com'
INFO: checking 'google.com' in hosts file...
INFO: 'google.com' is not in hosts file
INFO: URL http://google.com can be reached
INFO: checking if accessing https://google.com works
INFO: resolving 'google.com' using default system settings...
INFO: can't resolve 'google.com'
INFO: resolving 'google.com' using DNS server '10.7.12.7'...
INFO: can't resolve 'google.com' via DNS server '10.7.12.7'
!!! WARNING: DNS server '10.7.12.7' can NOT resolve 'google.com'.
!!! WARNING: this will make Sauce Connect unreliable.
INFO: resolving 'google.com' using DNS server '10.20.220.36'...
INFO: can't resolve 'google.com' via DNS server '10.20.220.36'
!!! WARNING: DNS server '10.20.220.36' can NOT resolve 'google.com'.
!!! WARNING: this will make Sauce Connect unreliable.
INFO: resolving 'google.com' using DNS server '8.8.8.8'...
INFO: can't resolve 'google.com'
INFO: resolving 'google.com' using DNS server '8.8.4.4'...
INFO: can't resolve 'google.com'
INFO: checking 'google.com' in hosts file...
INFO: 'google.com' is not in hosts file
INFO: URL https://google.com can be reached

1 个答案:

答案 0 :(得分:0)

您应该提供有关哪些操作系统(我怀疑是Windows)以及您正在使用哪种版本的SC的更多信息。

同时运行带有-vv --doctor命令行参数的Sauce Connect并发布输出可能有助于诊断。

另外,请查看此thread以供参考。