diff options
author | Andreas Nilsson <andreas.nilsson@10gen.com> | 2015-09-22 13:08:25 -0400 |
---|---|---|
committer | Andreas Nilsson <andreas.nilsson@10gen.com> | 2015-09-23 13:20:58 -0400 |
commit | fa24b6adab2f71a3c07d8810d04d5e0da4c5ac59 (patch) | |
tree | 6e5500ccedcbce55ca3234800faf73994554eea2 /jstests/auth | |
parent | 92e38e66a79d8fc374c6c8f8faa6244f94144904 (diff) | |
download | mongo-fa24b6adab2f71a3c07d8810d04d5e0da4c5ac59.tar.gz |
SERVER-20460 Make listIndexes authz check backwards compat
Diffstat (limited to 'jstests/auth')
-rw-r--r-- | jstests/auth/lib/commands_lib.js | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/jstests/auth/lib/commands_lib.js b/jstests/auth/lib/commands_lib.js index 7adaf6e754d..7b8f82b1c92 100644 --- a/jstests/auth/lib/commands_lib.js +++ b/jstests/auth/lib/commands_lib.js @@ -1664,7 +1664,7 @@ var authCommandsLib = { } ] }, - // test legacy (pre 3.0) way of authorizing listCollections + // Test legacy (pre 3.0) way of authorizing listCollections. { runOnDb: firstDbName, privileges: [ @@ -1705,6 +1705,16 @@ var authCommandsLib = { actions: ["listIndexes"] } ] + }, + // Test legacy (pre 3.0) way of authorizing listIndexes. + { + runOnDb: firstDbName, + privileges: [ + { + resource: {db: firstDbName, collection: "system.indexes"}, + actions: ["find"] + } + ] } ] }, |