MD3X-00-000310 - MongoDB must uniquely identify and authenticate organizational users (or processes acting on behalf of organizational users).

Information

To assure accountability and prevent unauthenticated access, organizational users must be identified and authenticated to prevent potential misuse and compromise of the system.

Organizational users include organizational employees or individuals the organization deems to have equivalent status of employees (e.g., contractors). Organizational users (and any processes acting on behalf of users) must be uniquely identified and authenticated for all accesses, except the following:

(i) Accesses explicitly identified and documented by the organization. Organizations document specific user actions that can be performed on the information system without identification or authentication; and
(ii) Accesses that occur through authorized use of group authenticators without individual authentication. Organizations may require unique identification of individuals using shared accounts, for detailed accountability of individual activity.

NOTE: Nessus has provided the target output to assist in reviewing the benchmark to ensure target compliance.

Solution

Prereq: To drop a user from a database, must have the 'dropUser' action on the database.

For any user not a member of an appropriate organization and has access to a database in the system run the following command:

// Change to the appropriate database
use <database>
db.dropUser(<username>, {w: 'majority', wtimeout: 5000}

If the MongoDB configuration file (default location: /etc/mongod.conf) does not contain

security: authorization: 'enabled'

Edit the MongoDB configuration file, add these parameters, stop/start (restart) any mongod or mongos process using this MongoDB configuration file.

See Also

https://dl.dod.cyber.mil/wp-content/uploads/stigs/zip/U_MDB_Enterprise_Advanced_3-x_V2R2_STIG.zip

Item Details

References: CAT|II, CCI|CCI-000764, Rule-ID|SV-221168r879589_rule, STIG-ID|MD3X-00-000310, STIG-Legacy|SV-96577, STIG-Legacy|V-81863, Vuln-ID|V-221168

Plugin: MongoDB

Control ID: 3e0a40af1ac801325eaab21e169aa11d8c449b8fc8cb294e8b2059334f4ef3ee