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

user shouldn't be able to create collection having a name prefixed by 'system.'

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major - P3
    • Resolution: Done
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: Storage
    • Labels:
      None
    • Operating System:
      ALL

      Description

      From Sridhar's email:

      This was from the field and I can reproduce it as follows

      I can use db.createCollection("system.foobar") to create a collection with the system prefix.

      I cannot seem to drop this collection since I get
      > db.system.foobar.drop()
      Wed Nov 16 16:30:11 uncaught exception: drop failed: {
      "ns" : "test.system.foobar",
      "errmsg" : "exception: can't drop system ns",
      "code" : 12502,
      "ok" : 0
      }

      There is a check in pdfile.cpp in dropNS that checks for this

        Attachments

          Issue Links

            Activity

              People

              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: