-
-
Notifications
You must be signed in to change notification settings - Fork 37.1k
SSL sockets may leak when keepalive is enabled #5699
Copy link
Copy link
Closed
Labels
confirmed-bugIssues and PRs for confirmed bugs.Issues and PRs for confirmed bugs.httpIssues and PRs related to the http subsystem.Issues and PRs related to the http subsystem.httpsIssues and PRs related to the https subsystem.Issues and PRs related to the https subsystem.memoryIssues and PRs related to Node.js memory management or memory footprint.Issues and PRs related to Node.js memory management or memory footprint.netIssues and PRs related to the net subsystem.Issues and PRs related to the net subsystem.
Description
Activity
Metadata
Metadata
Assignees
Labels
confirmed-bugIssues and PRs for confirmed bugs.Issues and PRs for confirmed bugs.httpIssues and PRs related to the http subsystem.Issues and PRs related to the http subsystem.httpsIssues and PRs related to the https subsystem.Issues and PRs related to the https subsystem.memoryIssues and PRs related to Node.js memory management or memory footprint.Issues and PRs related to Node.js memory management or memory footprint.netIssues and PRs related to the net subsystem.Issues and PRs related to the net subsystem.
issue is in: lib/_http_agent.js
The issue is reproducible whenever the
caproperty is set globally in the agent and an https request is made withhttps.request(ops)whereopsdoes not have the propertyca_http_agent.js @
Agent.prototype.createSocketthe
optionsare extended with the globaloptionsobject which containsca. IngetNamecais used in the name generation of the hash.however _http_agent.js @
Agent.prototype.addRequestThe
options(passed from the callhttps.request(ops)which don't have the propertyca) are used to get a hashtag which is now different. The socket leaks and is closed when the timeout hits. Meanwhile a new socket is created for the request.