-
Type:
Task
-
Resolution: Unresolved
-
Priority:
Unknown
-
None
-
Affects Version/s: None
-
Component/s: None
Use Case
As a Developer
I want the driver to use injected tls adapter for secure connections.
So that I can use SSL/TLS in JS runtimes that don't have node tls module.
User Experience
- Driver uses provided tls adapter instead of require('tls').
Risks/Unknowns
- We must verify that all usage scenarios are covered by the adapter interface.
- The tls.connect options object is complex. We must ensure that only the options the driver actually uses are included in our adapter interface definition and documented, minimizing the burden on implementers.
Acceptance Criteria
Implementation Requirements
- Remove import: remove require('tls') from all places inside src folder.
- Use tls adapter provided with the mongo client options.
- If a dns adapter is provided, the secure connection must use its lookup method.
Testing Requirements
- Existing integration tests should pass when custom tls adapter is provided, no node:tls should be imported in that case.
Documentation Requirements
- DOCSP ticket, API docs, etc
Follow Up Requirements
- additional tickets to file, required releases, etc
- if node behavior differs/will differ from other drivers, confirm with dbx devs what standard to aim for and what plan, if any, exists to reconcile the diverging behavior moving forward
- depends on
-
NODE-7382 Implement Pluggable DNS Adapter
-
- Backlog
-