Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

webdriver-manager does not respect NODE_TLS_REJECT_UNAUTHORIZED environment variable #3035

Closed
dsebastien opened this issue Mar 18, 2016 · 4 comments
Assignees

Comments

@dsebastien
Copy link
Contributor

Bug report

  • Node Version: 4.2.4
  • Protractor Version: 3.2.0
  • Operating System and Version Windows 10 x64
  • Configured environment variables:
  • HTTP_PROXY
  • HTTPS_PROXY
  • NODE_TLS_REJECT_UNAUTHORIZED=0
  • Environment: our corporate proxy does SSL termination, meaning that when going through it, it only gives back self-signed certificates
  • Steps to reproduce the bug

Execute webdriver-manager update behind a corporate proxy that performs SSL termination.
Expected behavior: successful download of https://selenium-release.storage.googleapis.com/xxx/selenium-server-standalone--xxx.jar

Result:
Updating selenium standalone
downloading https://selenium-release.storage.googleapis.com/2.51/selenium-server-standalone-2.51.0.jar...
Updating chromedriver
downloading https://chromedriver.storage.googleapis.com/2.21/chromedriver_win32.zip...
Error: Got error Error: SSL Error: SELF_SIGNED_CERT_IN_CHAIN from https://chromedriver.storage.googleapis.com/2.21/chromedriver_win32.zip
Error: Got error Error: SSL Error: SELF_SIGNED_CERT_IN_CHAIN from https://selenium-release.storage.googleapis.com/2.51/selenium-server-standalone-2.51.0.jar

@dsebastien
Copy link
Contributor Author

I've tested with webdriver-manager update --standalone --ignore_ssl, which seems a bit better but now I get a 403 and our A/V seems to think that the selenium jar is a virus... :)

You may consider this issue bogus given that the support is there, but maybe consider respecting the NODE_TLS_REJECT_UNAUTHORIZED environment variable?

@cnishina cnishina self-assigned this Mar 18, 2016
cnishina pushed a commit to cnishina/protractor that referenced this issue Mar 18, 2016
closes angular#3035

Note that in most cases, this should not have surfaced as an issue because
the base test mock modules will also try to turn on debug info.

Closes angular#3009
@cnishina
Copy link
Member

NODE_TLS_REJECT_UNAUTHORIZED looks like it will eventually be deprecated nodejs/node#5258.
Per request/request#1777, it looks like we need to set rejectUnauthorized to false in addition to setting strictSSL to false.

Since this is probably a setup / scenario that is difficult to test, the proposed solution is to create a branch and for you to test it out. After pulling down the branch pr_ssl, run the local webdriver with node bin/webdriver-manager update --ignore_ssl

https://github.com/cnishina/protractor/tree/pr_ssl

Let me know if that works.

@dsebastien
Copy link
Contributor Author

The pr_ssl branch does improve the situation a bit, but our corporate A/V and proxy are too strict:

  • the jar file is considered a virus by the A/V
  • the zip file is not accessible because of the proxy rules (forbidden category)

This is why we're now trying to host the files internally and use the alternate_cdn argument, which does not work like we need it to :p (see #3046).

Your modification should be merged on master though as it does provide an improvement to the scenario described in this issue.

@dsebastien
Copy link
Contributor Author

+1, thanks!

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

No branches or pull requests

3 participants