diff options
-rw-r--r-- | src/mongo/client/connpool.cpp | 1 | ||||
-rw-r--r-- | src/mongo/client/connpool.h | 1 | ||||
-rw-r--r-- | src/mongo/client/dbclient.cpp | 10 | ||||
-rw-r--r-- | src/mongo/client/dbclientinterface.h | 8 | ||||
-rw-r--r-- | src/mongo/db/security.h | 2 | ||||
-rw-r--r-- | src/mongo/db/security_common.cpp | 9 | ||||
-rw-r--r-- | src/mongo/s/shardconnection.cpp | 1 |
7 files changed, 1 insertions, 31 deletions
diff --git a/src/mongo/client/connpool.cpp b/src/mongo/client/connpool.cpp index 71cc6303b52..740249d87bb 100644 --- a/src/mongo/client/connpool.cpp +++ b/src/mongo/client/connpool.cpp @@ -113,7 +113,6 @@ namespace mongo { c.conn = NULL; } if ( alive ) { - c.conn->clearAuthenticationTable(); all.push_back( c ); } } diff --git a/src/mongo/client/connpool.h b/src/mongo/client/connpool.h index d0644533957..de823e342aa 100644 --- a/src/mongo/client/connpool.h +++ b/src/mongo/client/connpool.h @@ -333,7 +333,6 @@ namespace mongo { kill(); else */ - _conn->clearAuthenticationTable(); pool.release(_host, _conn); _conn = 0; } diff --git a/src/mongo/client/dbclient.cpp b/src/mongo/client/dbclient.cpp index a032968ad5d..041f712fc47 100644 --- a/src/mongo/client/dbclient.cpp +++ b/src/mongo/client/dbclient.cpp @@ -368,16 +368,6 @@ namespace mongo { return QueryOptions(0); } - void DBClientWithCommands::setAuthenticationTable( const AuthenticationTable& auth ) { - _authTable = auth; - _hasAuthentication = true; - } - - void DBClientWithCommands::clearAuthenticationTable() { - _authTable.clearAuth(); // This probably isn't necessary, but better to be safe. - _hasAuthentication = false; - } - inline bool DBClientWithCommands::runCommand(const string &dbname, const BSONObj& cmd, BSONObj &info, diff --git a/src/mongo/client/dbclientinterface.h b/src/mongo/client/dbclientinterface.h index ccfb8fc9277..510371f0cfd 100644 --- a/src/mongo/client/dbclientinterface.h +++ b/src/mongo/client/dbclientinterface.h @@ -569,8 +569,7 @@ namespace mongo { DBClientWithCommands() : _logLevel(0), _cachedAvailableOptions( (enum QueryOptions)0 ), - _haveCachedAvailableOptions(false), - _hasAuthentication(false) { } + _haveCachedAvailableOptions(false) { } /** helper function. run a simple command where the command expression is simply { command : 1 } @@ -865,9 +864,6 @@ namespace mongo { bool exists( const string& ns ); - virtual void setAuthenticationTable( const AuthenticationTable& auth ); - virtual void clearAuthenticationTable(); - /** Create an index if it does not already exist. ensureIndex calls are remembered so it is safe/fast to call this function many times in your code. @@ -938,8 +934,6 @@ namespace mongo { private: enum QueryOptions _cachedAvailableOptions; bool _haveCachedAvailableOptions; - AuthenticationTable _authTable; - bool _hasAuthentication; }; /** diff --git a/src/mongo/db/security.h b/src/mongo/db/security.h index 723eb9ed9b8..e5c5cd07ea7 100644 --- a/src/mongo/db/security.h +++ b/src/mongo/db/security.h @@ -90,8 +90,6 @@ namespace mongo { // Returns true if this AuthenticationInfo has been auth'd to use the internal user bool usingInternalUser(); - const AuthenticationTable getAuthTable() const; - // When TemporaryAuthReleaser goes out of scope it clears the temporary authentication set // in its AuthenticationInfo object, unless that AuthenticationInfo already had temporary // auth set at the time that the TemporaryAuthReleaser was initialized. diff --git a/src/mongo/db/security_common.cpp b/src/mongo/db/security_common.cpp index f071acbe385..59cb2d503d3 100644 --- a/src/mongo/db/security_common.cpp +++ b/src/mongo/db/security_common.cpp @@ -113,10 +113,6 @@ namespace mongo { // createPWDigest should really not be a member func DBClientConnection conn; internalSecurity.pwd = conn.createPasswordDigest(internalSecurity.user, str); - AuthenticationTable::getMutableInternalSecurityAuthenticationTable().addAuth( - "local", - internalSecurity.user, - Auth::WRITE ); return true; } @@ -159,9 +155,4 @@ namespace mongo { return authTable.getAuthForDb( dbname ).level >= level; } - const AuthenticationTable AuthenticationInfo::getAuthTable() const { - scoped_spinlock lk( _lock ); - return _authTable; - } - } // namespace mongo diff --git a/src/mongo/s/shardconnection.cpp b/src/mongo/s/shardconnection.cpp index d1f78e15388..6e1a44b2f67 100644 --- a/src/mongo/s/shardconnection.cpp +++ b/src/mongo/s/shardconnection.cpp @@ -167,7 +167,6 @@ namespace mongo { } void release( const string& addr , DBClientBase * conn ) { - conn->clearAuthenticationTable(); shardConnectionPool.release( addr , conn ); } |