Mongoose Authentication Failing

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Done
    • Priority: Critical - P2
    • None
    • Affects Version/s: 3.0.0
    • Component/s: MongoDB 3.2
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      Mongoose (NodeJS Mongo Driver) Authentication with Mongo DB 3 is failing with SHA-1 SCRAM credentials. I am passing username/password/authDB/etc., but it is not allowing me to connect and giving the following error: MongoError: Authentication failed.

      I am using the following lines to connect:

      var mongoose = require('mongoose');
      var db = mongoose.connect("mongodb://username:password@host:port/dbName?authSource=authDB&authMechanism=SCRAM-SHA-1",
      function (err, res) {
      if (err)

      { console.log ('ERROR: ' + err); }

      else

      { console.log ('Success'); }

      });

      Every time, it falls into the error condition.

            Assignee:
            Christian Amor Kvalheim
            Reporter:
            Bradley Barbee
            None
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: