Uploaded image for project: 'Node.js Driver'
  1. Node.js Driver
  2. NODE-6834

Flaky: x509 auth when a valid cert is provided but the certificate does not correspond to a user fails to authenticate [4]

    • Type: Icon: Build Failure Build Failure
    • Resolution: Unresolved
    • Priority: Icon: Unknown Unknown
    • None
    • Affects Version/s: None
    • Component/s: Flaky Test
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      CI: https://spruce.mongodb.com/task/mongo_node_driver_next_rhel80_large_Node22_test_x509_authentication_210720094d15bf72a07ba09e9957a8d9b8d81d80_25_03_05_17_16_30/logs?execution=0&sortBy=STATUS&sortDir=ASC

         1) x509 Authentication
              when a valid cert is provided but the certificate does not correspond to a user
                fails to authenticate:
            AssertionError: expected null to be an instance of MongoServerError
             at Context.<anonymous> (test/manual/x509_auth.test.ts:67:29)
             at processTicksAndRejections (node:internal/process/task_queues:105:5)
      

      Notes for whoever picks this up

      I spent a bit of time investigating this particular flake. I could not reproduce locally on a replica set, but I could reproduce locally on a sharded cluster. The tests are unusual - they configure the cluster with no authentication, then create / remove users in before and after hooks per test ( as needed ).

      My suspicion is that this is some sort of replication lag issue - the test failure occurs because we shouldn't be able to connect, but are successfully authenticating. This test also runs after the valid auth tests, which have created a valid user.

      It is probably worth trying to see if we can reproduce this issue with a different auth mechanism and maybe reporting this to the server, but I think that this is unlikely to be an issue in practice because creating / deleting the same user repeatedly is an unusual workflow and likely doesn't exist in the wild.

            Assignee:
            Unassigned Unassigned
            Reporter:
            bailey.pearson@mongodb.com Bailey Pearson
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              None
              None
              None
              None