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

Can client distinguish between "wrong password" and "wrong auth mechanism" failure?

    • Type: Icon: Task Task
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • 2.0.44
    • Affects Version/s: None
    • Component/s: None

      Can an application using the node driver distinguish (observe the difference between)

      • auth failed due to wrong authMechanism
      • auth failed due to wrong password

      This distinction matters if the application wants to implement an auth mechanism fallback such as "try SCRAM-SHA-1, then try MONGODB-CR". If the first (more secure) method fails because the password is wrong by one character, we don't want to attempt the less-secure method.

      Question raised on https://github.com/mongodb/node-mongodb-native/pull/1299#issuecomment-143265838

            Assignee:
            christkv Christian Amor Kvalheim
            Reporter:
            matt.kangas Matt Kangas
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: