Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-4241

Shell connections don't re-authenticate on reconnect

    • Type: Icon: Bug Bug
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • 2.1.0
    • Affects Version/s: None
    • Component/s: Security, Shell
    • None
    • ALL

      > mongo
      MongoDB shell version: 2.0.1
      connecting to: test
      test[17:27:54]> db.foo.find()
      error:

      { "$err" : "unauthorized db:test lock type:-1 client:127.0.0.1", "code" : 10057 } test[17:27:59]> db.auth('spencer','password') 1 test[17:28:12]> db.foo.find() { "_id" : ObjectId("4ebafe6909b6ffecbd780b6b"), "a" : 1 }

      // RESTART MONGOD SERVER

      test[17:28:19]> db.foo.find()
      Wed Nov 9 17:30:04 DBClientCursor::init call() failed
      Wed Nov 9 17:30:04 query failed : test.foo {} to: 127.0.0.1
      Error: error doing query: failed
      Wed Nov 9 17:30:04 trying reconnect to 127.0.0.1
      Wed Nov 9 17:30:04 reconnect 127.0.0.1 ok
      test[17:30:4]> db.foo.find()
      error: {
      "$err" : "unauthorized db:test lock type:-1 client:127.0.0.1",
      "code" : 10057
      }

            Assignee:
            kristina Kristina Chodorow (Inactive)
            Reporter:
            spencer@mongodb.com Spencer Brody (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: