-
Type: Build Failure
-
Resolution: Fixed
-
Priority: Major - P3
-
Affects Version/s: None
-
Component/s: Testing
The X509 tests in https://github.com/mongodb/node-mongodb-native/blob/main/test/integration/auth/ssl_x509_connect.test.js are both old and are not running as part of any CI runs. (If they did run, they'd fail as they aren't even setting the TLS options correctly as there is no server mongo client option.)
These should be refactored to actually run and pass, since out manual tls tests aren't handling all the different scenarios.
Acceptance Criteria
Add a script that configures a user for x509 authentication- Ended up implementing before/after test hooks that configure a user for x509 auth, because not all tests can run with an x509 user.
- Add a variant to CI that runs x509 authentication tests.
- Test against latest server and sharded cluster.
- Latest, because x509 auth isn't dependent on server versions > 3.4.
- Sharded, because x509 isn't dependent on topology and we're headed in the direction of sharded by default.
- Test against latest server and sharded cluster.
- Add prose tests that test x509 authentication following our existing pattern for testing authencation
- Confirm that when authenticating with x509 auth, a user can successfully authenticate.
- Confirm that when authenticating with invalid credentials, we fail to authenticate.