summaryrefslogtreecommitdiff
path: root/src/mongo/db/commands/authentication_commands.cpp
diff options
context:
space:
mode:
authorShreyas Kalyan <shreyas.kalyan@10gen.com>2019-02-04 14:08:32 -0500
committerShreyas Kalyan <shreyas.kalyan@10gen.com>2019-02-26 19:13:19 -0500
commita9277e874039f32ce0d848fcdfb10de705c96fd9 (patch)
tree6bf222fec20aa30afe648d54becb0e0922707b0d /src/mongo/db/commands/authentication_commands.cpp
parent1ba2e45711fb15801539d0bec022a2a474155c09 (diff)
downloadmongo-a9277e874039f32ce0d848fcdfb10de705c96fd9.tar.gz
SERVER-39058 Synchronize user set modification in AuthorizationSession with Client
Diffstat (limited to 'src/mongo/db/commands/authentication_commands.cpp')
-rw-r--r--src/mongo/db/commands/authentication_commands.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/mongo/db/commands/authentication_commands.cpp b/src/mongo/db/commands/authentication_commands.cpp
index 90fe580b0b6..7666955b122 100644
--- a/src/mongo/db/commands/authentication_commands.cpp
+++ b/src/mongo/db/commands/authentication_commands.cpp
@@ -121,7 +121,7 @@ Status _authenticateX509(OperationContext* opCtx, const UserName& user, const BS
}
}
- authorizationSession->grantInternalAuthorization();
+ authorizationSession->grantInternalAuthorization(client);
}
// Handle normal client authentication, only applies to client-server connections
else {
@@ -336,14 +336,14 @@ public:
const BSONObj& cmdObj,
BSONObjBuilder& result) {
AuthorizationSession* authSession = AuthorizationSession::get(Client::getCurrent());
- authSession->logoutDatabase(dbname);
+ authSession->logoutDatabase(opCtx, dbname);
if (getTestCommandsEnabled() && dbname == "admin") {
// Allows logging out as the internal user against the admin database, however
// this actually logs out of the local database as well. This is to
// support the auth passthrough test framework on mongos (since you can't use the
// local database on a mongos, so you can't logout as the internal user
// without this).
- authSession->logoutDatabase("local");
+ authSession->logoutDatabase(opCtx, "local");
}
return true;
}