mirror of
https://github.com/mongodb/mongo.git
synced 2024-11-28 07:59:02 +01:00
SERVER-17669 Remove web auth prompt for non-auth mongod
This commit is contained in:
parent
e7497e9c47
commit
2aeb5a17b1
@ -110,6 +110,10 @@ namespace mongo {
|
||||
vector<string>& headers,
|
||||
const SockAddr &from) {
|
||||
|
||||
if ( !cc().getAuthorizationSession()->getAuthorizationManager().isAuthEnabled() ) {
|
||||
return true;
|
||||
}
|
||||
|
||||
if ( from.isLocalHost() && !_webUsers->haveAdminUsers(txn) ) {
|
||||
cc().getAuthorizationSession()->grantInternalAuthorization();
|
||||
return true;
|
||||
|
Loading…
Reference in New Issue
Block a user