7.2 Ensure appropriate database file permissions are set.

Information

MongoDB database files need to be protected using file permissions.

This will restrict unauthorized users from accessing the database.

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

Solution

Set ownership of the database file to mongodb user and remove other permissions using the following commands:

chmod 770 /var/lib/mongodb
chown mongodb:mongodb /var/lib/mongodb

See Also

https://workbench.cisecurity.org/benchmarks/15858

Item Details

Category: ACCESS CONTROL, MEDIA PROTECTION

References: 800-53|AC-3, 800-53|AC-5, 800-53|AC-6, 800-53|MP-2, CSCv7|14.6

Plugin: Windows

Control ID: e2e041a201e9f7ff8be3ff408fa0fc6165f682050d8d6ff01c7ec41e8e067a0a