-
Notifications
You must be signed in to change notification settings - Fork 29.6k
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
Error: connect EPERM when connecting to https server with self signed certificate #20019
Comments
I think this might be a duplicate of #16196? |
It's very likely a duplicate of that issue, although I'm not 100% certain. The target server I was testing with only supports the following ciphers:
|
Can you connect with |
Output from
|
Okay, and what happens when you pass in the certificate with |
|
That's progress. :-). What happens when you do this? const options = url.parse('https://target.localhost');
options.ecdhCurve = 'auto';
https.get(options, ...); What when you add this? options.ca = fs.readFileSync('./caTrust.cer'); |
Both of them work when i remove the following lines. See initial ticket comment.
|
I don't see commits between v8.5.0 and v8.6.0 that are plausible candidates for such a regression. Are you sure v8.6.0 is the first release where this started happening for you? |
Yes, issue started with v8.6.0. The exactly line causing the issue is: Overwriting the entire globalAgent.options property (initially equals {path: null}) is causing the problem. Either of the following lines work:
|
Maybe due to #14564? |
It works after reverting ee157e5. I'm going to close this since options object shouldn't have been overwritten in the first place. Thanks for help. |
cc @bengl since I doubt that's the intended behavior. |
When connecting to https url with self signed certificate, the following error is thrown:
The issue isn't system independent and happens starting with nodev8.6.0. The code below works fine on nodev8.5.0 or lower on same machine
When using
request
library to make the https call, it throws a slightly different error:Error: connect ENOENT
The text was updated successfully, but these errors were encountered: