TMA-MONGODB-2.1
Ensure Authentication is configured
Mô tả
This setting ensures that all clients, users, servers are required to authenticate before being granted access to the MongoDB database. Authentication is the process of verifying the identity of a client. When access control, i.e. authorization, is enabled, MongoDB requires all clients to authenticate themselves in order to determine their access. Checks the YAML config file /etc/mongod.conf (SKIP when it does not exist).
Cách kiểm tra
Phương pháp kiểm tra: Mẫu tệp
- Tệp
/etc/mongod.conf- Mẫu khớp
(?m)^[ \t]*authorization:[ \t]*['\x22]?enabled\b
Cách khắc phục
Phương pháp khắc phục: Hướng dẫn hoặc bản vá hạ tầng
Create a user administrator first (use admin; db.createUser({user: '<admin>', pwd: passwordPrompt(), roles: [{role: 'userAdminAnyDatabase', db: 'admin'}]})), then set 'security: authorization: enabled' in /etc/mongod.conf and restart mongod.
Thuộc tính
- Hệ điều hành
- Bất kỳ
- Thẻ
- mongodbauthentication
- Tham chiếu
- CIS MongoDB 8 Benchmark v2.0.0 - 2.1 Ensure Authentication is configured
Kiểm tra máy này
Chạy lệnh này trên máy bạn được phép kiểm tra. Lần quét chỉ ở chế độ đọc.
tmaegis scan --target mongodb