summaryrefslogtreecommitdiff
path: root/jstests/auth
diff options
context:
space:
mode:
authorAndreas Nilsson <andreas.nilsson@10gen.com>2015-03-27 10:36:56 -0400
committerAndreas Nilsson <andreas.nilsson@10gen.com>2015-03-27 11:16:32 -0400
commit1fc9d37170bcf29068f02cc2898436281fe16d6a (patch)
tree96614b262db1c2aaecacca332354a470f59b748a /jstests/auth
parent37a3732ba1e4e801ffe01804687a4958b53a5fae (diff)
downloadmongo-1fc9d37170bcf29068f02cc2898436281fe16d6a.tar.gz
SERVER-17529 Let find on system.namespaces imply listCollections
Diffstat (limited to 'jstests/auth')
-rw-r--r--jstests/auth/lib/commands_lib.js10
1 files changed, 10 insertions, 0 deletions
diff --git a/jstests/auth/lib/commands_lib.js b/jstests/auth/lib/commands_lib.js
index a832e68609f..14299d2f5e9 100644
--- a/jstests/auth/lib/commands_lib.js
+++ b/jstests/auth/lib/commands_lib.js
@@ -1488,6 +1488,16 @@ var authCommandsLib = {
actions: ["listCollections"]
}
]
+ },
+ // test legacy (pre 3.0) way of authorizing listCollections
+ {
+ runOnDb: firstDbName,
+ privileges: [
+ {
+ resource: {db: firstDbName, collection: "system.namespaces"},
+ actions: ["find"]
+ }
+ ]
}
]
},