MongoDB
TMA-MONGODB-5.1
Ensure that system activity is audited
Description
Track access and changes to database configurations and data. MongoDB Enterprise includes a system auditing facility that can record system events (e.g. user operations, connection events) on a MongoDB instance. These audit records permit forensic analysis and allow administrators to verify proper controls. Checks the YAML config file /etc/mongod.conf (SKIP when it does not exist). Auditing requires MongoDB Enterprise or Percona Server for MongoDB.
Méthode de vérification
Méthode d'audit: Motif de fichier
- Fichier
/etc/mongod.conf- Motif
(?m)^auditLog:[ \t]*\n(?:[ \t]*(?:#[^\n]*)?\n|[ \t]+[^\n]*\n)*?[ \t]+destination:[ \t]*['\x22]?(?:file|syslog|console)\b
Méthode de correction
Méthode de correction: Recommandation ou correctif d'infrastructure
Add 'auditLog: {destination: file, format: JSON, path: /var/log/mongodb/auditLog.json}' (or destination: syslog) to /etc/mongod.conf and restart mongod.
Propriétés
- Systèmes d'exploitation
- Tous
- Étiquettes
- mongodbloggingaudit
- Référence
- CIS MongoDB 8 Benchmark v2.0.0 - 5.1 Ensure that system activity is audited
Vérifier cet hôte
Exécutez cette commande sur une machine que vous êtes autorisé à auditer. L'analyse est en lecture seule.
tmaegis scan --target mongodb