summaryrefslogtreecommitdiff
path: root/src/mongo/db/auth
diff options
context:
space:
mode:
authorSara Golemon <sara.golemon@mongodb.com>2018-04-10 16:24:53 -0400
committerSara Golemon <sara.golemon@mongodb.com>2018-04-18 17:25:40 -0400
commit14d03a79f55d69ccdd27bb4a08906a4be5eb4a8e (patch)
treefb4eeea5ea2be69bd93e9050ede9ebcad1aefe92 /src/mongo/db/auth
parentd31c1e77117668ae11a967311d251ad0a4f26d01 (diff)
downloadmongo-14d03a79f55d69ccdd27bb4a08906a4be5eb4a8e.tar.gz
SERVER-34230 Add ActionType and Commands for Free Monitoring
Diffstat (limited to 'src/mongo/db/auth')
-rw-r--r--src/mongo/db/auth/action_types.txt2
-rw-r--r--src/mongo/db/auth/role_graph_builtin_roles.cpp4
2 files changed, 5 insertions, 1 deletions
diff --git a/src/mongo/db/auth/action_types.txt b/src/mongo/db/auth/action_types.txt
index b10bdf2c1c9..d641378e162 100644
--- a/src/mongo/db/auth/action_types.txt
+++ b/src/mongo/db/auth/action_types.txt
@@ -19,6 +19,7 @@
"changeOwnPassword",
"changeOwnCustomData",
"changeStream",
+"checkFreeMonitoringStatus",
"cleanupOrphaned",
"closeAllDatabases", # Deprecated, needs to stay around for backwards compatibility
"collMod",
@@ -103,6 +104,7 @@
"serverStatus",
"setAuthenticationRestriction",
"setFeatureCompatibilityVersion",
+"setFreeMonitoring",
"setParameter",
"shardCollection", # Not used for permissions checks, but to id the event in logs.
"shardingState",
diff --git a/src/mongo/db/auth/role_graph_builtin_roles.cpp b/src/mongo/db/auth/role_graph_builtin_roles.cpp
index 79be5b05108..5b8cd34ea8f 100644
--- a/src/mongo/db/auth/role_graph_builtin_roles.cpp
+++ b/src/mongo/db/auth/role_graph_builtin_roles.cpp
@@ -182,6 +182,7 @@ MONGO_INITIALIZER(AuthorizationBuiltinRoles)(InitializerContext* context) {
// clusterMonitor role actions that target the cluster resource
clusterMonitorRoleClusterActions
+ << ActionType::checkFreeMonitoringStatus
<< ActionType::connPoolStats
<< ActionType::getCmdLineOpts
<< ActionType::getLog
@@ -250,7 +251,8 @@ MONGO_INITIALIZER(AuthorizationBuiltinRoles)(InitializerContext* context) {
<< ActionType::listShards // clusterMonitor gets this also
<< ActionType::flushRouterConfig // hostManager gets this also
<< ActionType::cleanupOrphaned
- << ActionType::setFeatureCompatibilityVersion;
+ << ActionType::setFeatureCompatibilityVersion
+ << ActionType::setFreeMonitoring;
clusterManagerRoleDatabaseActions
<< ActionType::splitChunk